Commit Graph

1665 Commits

Author SHA1 Message Date
Binh Bui
143ec95bf0 Update [Vaadin-Directory] previewUri in all-badge-examples.js (#1496)
* Changed previewUri in all-badge
2018-02-13 03:18:10 +01:00
Binh Bui
e773a9f47d Added [Vaadin-Directory] badge service (#1474)
* Integrated Vaadin service to server.js & load age from color-formatters lib

* Added 8 tests for Vaadin services

* Added Vaadin badge to main page under Misc

* Used checkErrorResponse() and fix 404 test return value

* Removed maturity from URL field option

* Remove duplicate `age` module import

* Removed comment

* Changed several URI fields and fixed according tests
2018-02-13 00:52:46 +01:00
Marcin Mielnicki
17b4a70411 [npm bountysource cdnjs circleci clojars docker gem homebrew itunes microbadger nexus requires shippable suggest uptimerobot] Service tests for NPM total downloads + invalidJSON helper (#1471)
* Service tests for NPM total downloads

* Spread syntax removed

* service-tests/helpers/mocks.js -> service-tests/helpers/response-fixtures.js

* Another value an invalid JSON in response-fixtures

* Using invalidJSON helper in service tests

* Working example in a service test of microbadger

* isPercentage supports decimal and integer values
2018-02-12 21:36:23 +01:00
Tomek Łaziuk
8ad176d014 [bundlephobia] add badge for the npm package size (#1481)
* Added a shield for calculating npm bundle sizes

* Fix linting errors

* Fixed badges for bundlephobia

* Remove un-required keywords

* Simplified handler based on feedback

* Use isFileSize for validation

* Convert camel-cased error codes to space separated ones

* Updated error format

* Fixed error formatting

* Renamed gzip to minzip

* Fixes lint error

* Remove test that times out

* refactor tests to make it more readable

* meaningless change

* use trim
2018-02-03 08:31:10 -08:00
chris48s
cbb263b102 service tests for [cocoapods] (#1472)
* service tests for [cocoapods]

* Add tests for CocoaPods Endpoints

Bug fixes:
* Call `metrics.cocoapods.org` API endpoints over HTTPs
* Show correct left-side badge text on error in version/platform/license badges
* Handle null doc coverage gracefully
* Add handling for 'not found' responses

* drop last param to checkErrorResponse

* remove redundant line

* set badge label using more terse notation

* specify allowed platform values
2018-02-03 08:11:28 -08:00
chris48s
e4199bc806 service tests for [david] (#1465)
* service tests for [david]

* update 500 handling
2018-02-02 15:11:50 -08:00
greenkeeper[bot]
ef038b8049 Update mocha to the latest version 🚀 (#1459)
* chore(package): update mocha to version 5.0.0

* Update package-lock
2018-02-02 14:58:14 -08:00
greenkeeper[bot]
4ffdd85177 Update semver to the latest version 🚀 (#1457)
* fix(package): update semver to version 5.5.0

* Update package-lock
2018-02-02 14:54:26 -08:00
greenkeeper[bot]
1314258913 Update is-svg to the latest version 🚀 (#1483)
* chore(package): update is-svg to version 3.0.0

* Update package-lock
2018-02-02 14:44:29 -08:00
Paul Melnikow
e6de92c6ba Upgrade to next.js patched for CVE-2018-6184 (#1485)
This clears the GitHub warning for the vulnerability that shows up for maintainers. Note the vulnerability does not affect our deployment, which is static, using `next export`.

https://github.com/zeit/next.js/releases/tag/4.2.3
https://nvd.nist.gov/vuln/detail/CVE-2018-6184
2018-02-02 14:40:59 -08:00
Danial
cec40ad46c update tests (#1482) 2018-02-02 10:10:40 +13:00
Pyves
435903ae4a [CodeClimate] Fix remaining badges (#1387)
* Fixed remaining CodeClimate badges

* Added explicit percentage keyword and dropped top level URL

* Merged the two badge handlers into one

* Removed trailing space

* Switched to "dash" URL style

* Reinstated top-level URL

* Swicthed to use letter as optional keyword

* Updated badge examples

* Cleaned up

* Changed badge label to technical debt

* Switched tests to more mainstream projects as previous ones were deleted

* Rearranged badge URLs and default formats

* Updated examples
2018-02-01 09:33:29 +13:00
chris48s
b7228ae89e update codacy urls (#1477) 2018-02-01 09:24:42 +13:00
George Hopkins
0fd69332bd Add Windows logo (#1467) 2018-01-24 09:54:51 +13:00
chris48s
ec38c2e4da [shippable] add tests for shippable service (#1362)
* add test suite to formalise existing behaviour of shippable service

* throw more descriprive errors, use es6 declarations

* switch from SVG parsing to shippable API

* add test case for unexpected status code

* remove unused import

* link to source for status codes
2018-01-22 19:28:59 -08:00
chris48s
3c551a6156 clarify default for Uptime Robot ratio (#1463)
Fix #1462
2018-01-21 18:01:31 -05:00
Danial
9aafe86247 Show logos by default on social badges (regression fix) (#1456)
* Show logos on social badges

* Revert "Showcase logos in social badges on the front page"

This reverts commit 61fa22b7e4.

* Update footer badges to all be social style

as per reverted commit 61fa22b7e4
2018-01-21 23:57:58 +01:00
chris48s
e3ac9c3db5 service tests for [itunes] (#1464) 2018-01-21 17:50:04 -05:00
Paul Melnikow
1d8926672c Fix PR metadata auth [cran] (#1454)
Match work done in #1453 to our CI setup.
2018-01-16 13:15:15 -05:00
chris48s
7c6723a79d service tests for [docker] (#1428) 2018-01-15 22:03:52 -05:00
Paul Melnikow
eacfc1497a For service tests, get PR metadata from Github API (#1453)
Rather than depend on Shields production, use the GitHub auth info from CI. It's disorienting to have our own CI go down when production is down. It also makes it harder to review PRs when there are ops issues.
2018-01-15 21:53:15 -05:00
Danial
65e1d69f53 [badge/dynamic/json] fix colorscheme on error (#1445)
* [FIX] error colorscheme

* throw error if jsonpath query non existent

* fixup

* show brightgreen badge by default

* update test

* let -> var

* set lightgrey when no uri specified

* update tests

* red color for no uri specified

* dynamic badge use setBadgecolor()
2018-01-16 13:53:30 +13:00
chris48s
e1f0e2598d tests for ruby [gem] service (#1444)
* add tests for ruby gems version badge

* add tests for ruby gems users badge

* add tests for ruby gems rank badge

* add tests for ruby gems downloads badges

* don't allow 0th rank

* move version info to left side of badge
2018-01-15 15:20:48 -05:00
Vladimir Starkov
a681fdaa87 Fix docker run (#1439)
* fix: update nodejs version to latest LTS, to fullfill check-node-version. close #1437

* docs: add docker run example without shields.env file, because there is no such file in a repo and container wont start

* fix: docker build project, clean npm and run production mode. close #1373
2018-01-15 15:19:28 -05:00
Paul Melnikow
6b26affb5f Uptime Robot: Use regex that accepts decimals (#1448)
For #1359

This failure from https://circleci.com/gh/badges/shields/1411?utm_campaign=vcs-integration-link&utm_medium=referral&utm_source=github-build-link

```
  26) Uptime Robot
       Uptime Robot: Percentage (valid)
         
  [ GET http://localhost:1111/uptimerobot/ratio/m778918918-3e92c097147760ee39d02d36.json ]:
     ValidationError: child "value" fails because ["value" with value "99.992%" fails to match the required pattern: /^[0-9]+%$/]
      at Object.exports.process (node_modules/joi/lib/errors.js:190:19)
      at internals.Object._validateWithOptions (node_modules/joi/lib/types/any/index.js:669:31)
      at module.exports.internals.Any.root.validate (node_modules/joi/lib/index.js:139:23)
      at Object.pathMatch.matchJSONTypes (node_modules/icedfrisby/lib/pathMatch.js:303:9)
      at node_modules/icedfrisby/lib/icedfrisby.js:703:10
      at IcedFrisbyNock._invokeExpects (node_modules/icedfrisby/lib/icedfrisby.js:1294:33)
      at start (node_modules/icedfrisby/lib/icedfrisby.js:1274:12)
      at Request.runCallback [as _callback] (node_modules/icedfrisby/lib/icedfrisby.js:1232:16)
      at Request.self.callback (node_modules/request/request.js:186:22)
      at Request.<anonymous> (node_modules/request/request.js:1163:10)
      at IncomingMessage.<anonymous> (node_modules/request/request.js:1085:12)
      at endReadableNT (_stream_readable.js:1056:12)
      at _combinedTickCallback (internal/process/next_tick.js:138:11)
      at process._tickDomainCallback (internal/process/next_tick.js:218:9)

  27) Uptime Robot
       Uptime Robot: Percentage (valid, with numberOfDays param)
         
  [ GET http://localhost:1111/uptimerobot/ratio/7/m778918918-3e92c097147760ee39d02d36.json ]:
     ValidationError: child "value" fails because ["value" with value "99.967%" fails to match the required pattern: /^[0-9]+%$/]
      at Object.exports.process (node_modules/joi/lib/errors.js:190:19)
      at internals.Object._validateWithOptions (node_modules/joi/lib/types/any/index.js:669:31)
      at module.exports.internals.Any.root.validate (node_modules/joi/lib/index.js:139:23)
      at Object.pathMatch.matchJSONTypes (node_modules/icedfrisby/lib/pathMatch.js:303:9)
      at node_modules/icedfrisby/lib/icedfrisby.js:703:10
      at IcedFrisbyNock._invokeExpects (node_modules/icedfrisby/lib/icedfrisby.js:1294:33)
      at start (node_modules/icedfrisby/lib/icedfrisby.js:1274:12)
      at Request.runCallback [as _callback] (node_modules/icedfrisby/lib/icedfrisby.js:1232:16)
      at Request.self.callback (node_modules/request/request.js:186:22)
      at Request.<anonymous> (node_modules/request/request.js:1163:10)
      at IncomingMessage.<anonymous> (node_modules/request/request.js:1085:12)
      at endReadableNT (_stream_readable.js:1056:12)
      at _combinedTickCallback (internal/process/next_tick.js:138:11)
      at process._tickDomainCallback (internal/process/next_tick.js:218:9)
```
2018-01-15 15:15:23 -05:00
Paul Melnikow
e358ebe6b3 Refactor LRU cache test asserts (#1418) 2018-01-15 14:15:27 -05:00
greenkeeper[bot]
b422e880c1 Update prettier to the latest version 🚀 (#1434) 2018-01-15 14:14:08 -05:00
Paul Melnikow
606946f24a Log + fail tests on unhandled promise rejections (#1424) 2018-01-14 16:57:40 -05:00
chris48s
be3bc45d66 service tests for [homebrew] (#1443)
* add tests and 'not found' handling for homebrew service

* add test with mocked response
2018-01-14 16:51:24 -05:00
Thaddee Tyl
09a2ca144d Tweak IP and badge type rate limits 2018-01-13 18:34:48 +01:00
Thaddee Tyl
61fa22b7e4 Showcase logos in social badges on the front page 2018-01-13 15:33:41 +01:00
Vladimir Starkov
db39093fa7 fix: add missing git to apk installation script. close #1435 (#1436) 2018-01-11 16:55:33 -05:00
Paul Melnikow
864b194e5c Add Joi to greenkeeper ignore (#1430) 2018-01-09 11:50:43 -05:00
Thaddee Tyl
ac8935cecb Add rate limiting
We now rate limit IPs, referers and badge type.
2018-01-09 02:35:51 +01:00
Thaddee Tyl
0da212b7de Upgrade to camp 17.2.1 2018-01-09 01:25:10 +01:00
Paul Melnikow
7c1a3fef69 Adopt Chai for assertions (#1419) 2018-01-08 14:18:07 -07:00
chris48s
2de53ce7bd add tests for [hackage] (#1416)
* add tests for hackage, handle 'not found'

* add 'not found' case for hackage-deps

* use es6 declarations

* change badge label to 'dependencies'
2018-01-06 22:02:34 -07:00
Michael
a55ab15de2 fix inline image path (#1427) 2018-01-06 08:44:11 -07:00
greenkeeper[bot]
2013968990 Update danger to the latest version 🚀 (#1414) 2018-01-05 22:09:25 -07:00
chris48s
e614d19355 service tests for [uptimerobot] (#1426)
* use the same error handling on /status and /ratio endpoints

* add service tests for uptime robot
2018-01-05 20:51:05 -07:00
Daniel Lo Nigro
02683afd04 Don't crash when logo passed as integer (#1319) 2018-01-04 17:11:59 -07:00
chris48s
e91c9fc7ab Add tests for Circle-CI (#1421) 2018-01-05 12:16:25 +13:00
Paul Melnikow
ccb3eb8fdf Fix January unit test (#1417) 2018-01-03 20:37:35 -07:00
chris48s
9cb9d5984d [requires] add tests for requires.io service, review error handling (#1361) 2018-01-02 20:13:10 -07:00
Danial
503618443e Add Discord logo (#1413) 2018-01-03 10:09:01 +13:00
Sebastian Staudt
e62c085922 Update URL for Homebrew formula versions (#1408)
braumeister.org is now part of Homebrew and available at formulae.brew.sh.
2018-01-01 17:40:05 -05:00
chris48s
e2ee997f07 service tests for [clojars] (#1410) 2018-01-01 17:15:55 -05:00
chris48s
21b1ad73e7 Service tests for [cdnjs] (#1409) 2018-01-01 17:14:16 -05:00
chris48s
438e47adfb Add tests for codeship service (#1411) 2018-01-01 17:10:02 -05:00
Paul Melnikow
60959bf7e7 Use github auth in php-v badges (#1403)
To fix service test that fails in CI (due to no github auth) https://github.com/badges/shields/issues/1359#issuecomment-354184074

- DRY getPhpReleases()
- Pass named options to regularUpdate
    - Add json option
- php-version: Move helpers before functions, and move exports to end
2017-12-28 21:30:30 -05:00