Skip to content

Commit

Permalink
badges#745 | badges#937 : create github service-test
Browse files Browse the repository at this point in the history
Add file size test
  • Loading branch information
webcaetano committed Apr 29, 2017
1 parent d0469c2 commit 80e042b
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions service-tests/github.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,13 @@ const ServiceTester = require('./runner/service-tester');
const t = new ServiceTester({ id: 'github', title: 'GitHub' });
module.exports = t;

t.create('File size')
.get('/size/webcaetano/craft/build/craft.min.js.json')
.expectJSONTypes(Joi.object().keys({
name: Joi.equal('size'),
value: Joi.string().regex(/^[0-9]*[.]?[0-9]+\s(B|kB|MB|GB|TB|PB|EB|ZB|YB)$/)
}));

t.create('downloads for release without slash')
.get('/downloads/atom/atom/v0.190.0/total.json')
.expectJSONTypes(Joi.object().keys({
Expand Down

0 comments on commit 80e042b

Please sign in to comment.