Fix [CodeclimateCoverage] tests (#4927)

This commit is contained in:
Pierre-Yves B
2020-04-19 17:06:35 +02:00
committed by GitHub
parent 2c89a8c59f
commit a2e0e11ead
2 changed files with 8 additions and 2 deletions

View File

@@ -4,15 +4,18 @@ const Joi = require('@hapi/joi')
const { isIntegerPercentage } = require('../test-validators')
const t = (module.exports = require('../tester').createServiceTester())
// Examples for this service can be found through the explore page:
// https://codeclimate.com/explore
t.create('test coverage percentage')
.get('/coverage/jekyll/jekyll.json')
.get('/coverage/codeclimate/minidoc.json')
.expectBadge({
label: 'coverage',
message: isIntegerPercentage,
})
t.create('test coverage letter')
.get('/coverage-letter/jekyll/jekyll.json')
.get('/coverage-letter/codeclimate/minidoc.json')
.expectBadge({
label: 'coverage',
message: Joi.equal('A', 'B', 'C', 'D', 'E', 'F'),