Files
shields/services/github/github-sponsors.tester.js
2021-07-09 12:53:55 +01:00

22 lines
502 B
JavaScript

import { isMetric } from '../test-validators.js'
import { ServiceTester } from '../tester.js'
export const t = new ServiceTester({
id: 'GithubSponsors',
title: 'Github Sponsors',
pathPrefix: '/github',
})
t.create('Sponsors').get('/sponsors/Homebrew.json').expectBadge({
label: 'sponsors',
message: isMetric,
color: 'blue',
})
t.create('Sponsors (user not found)')
.get('/sponsors/badges-non-exist.json')
.expectBadge({
label: 'sponsors',
message: 'user/org not found',
})