Files
shields/services/puppetforge/puppetforge-module-pdk-version.tester.js
chris48s 83c3c70908 refactor [puppetforge] service, add tests (#3275)
This migrates the puppetforge-modules from legacy
services to the new service arch
There are also some changes to the puppetforge-users
badges, but its just moving code around
2019-04-07 19:35:30 +01:00

26 lines
591 B
JavaScript

'use strict'
const { isSemver } = require('../test-validators')
const t = (module.exports = require('../tester').createServiceTester())
t.create('PDK version')
.get('/tragiccode/azure_key_vault.json')
.expectBadge({
label: 'pdk version',
message: isSemver,
})
t.create("PDK version (library doesn't use the PDK)")
.get('/camptocamp/openssl.json')
.expectBadge({
label: 'pdk version',
message: 'none',
})
t.create('PDK version (not found)')
.get('/notarealuser/notarealpackage.json')
.expectBadge({
label: 'pdk version',
message: 'not found',
})