Commit Graph

729 Commits

Author SHA1 Message Date
seetd
54bcedc0f4 Add [W3C] Markup Validation Service Badge (#3833) (#4148)
* Add W3C Markup Validation Service Badge (#3833)

* Move helper functions into different file and added unit tests

* Remove unnecessary comments from spec file

* pr changes move code into transform method and validation of messages

* use joi.string().regex instead of custom validator

* Simplify the fetch, handle methods. Make Joi validation for string

* Remove empty parameter from tests and label from render method

* encodeUri on the doc and schema properties send to API

* Documentation and remove unnecessary Object.keys call

* Use regular expressions to make tests less brittle

* made service less for message and color more generic and less brittle

* Throw standard NoFound exception for invalid URL. Use w3c endpoint

* use sazerac for w3c-validation-helper.spec.js

* Replace documentation API url and API documentation url

* Switch back to https://validator.nu endpoint. Remove html4 assertions

* Increase strictness of NotFound checks
2019-10-21 18:40:14 -05:00
Michael Schmitz
f82f7b798d [gitlab] Add documentation for publicity state of pipelines (#4218)
* Add documentation for publicity state of pipelines

* Modify visual picture to be smaller and add red circle to mark important setting

* Adapt suggestion

Co-Authored-By: Caleb Cartwright <calebcartwright@users.noreply.github.com>
2019-10-20 12:14:55 -05:00
Caleb Cartwright
68c8b94d0c tests: fix CodeClimate Analysis service tests (#4191) 2019-10-18 13:33:12 -05:00
Caleb Cartwright
c71e9fe007 tests: fix aur license test (#4192) 2019-10-18 12:01:14 -05:00
Michael Schmitz
c729ef8ece Adjust new [swagger] endpoint (#4193)
* Change to new Url supporting OAS 3

* Change to new URL
2019-10-18 09:10:57 -05:00
Joe Clay
62bee16975 Add Crates.io recent downloads badge (fixes #4186), run [Crates] (#4187)
* Add Crates.io recent downloads badge (fixes #4186)

* Rename extractDownloads to transform

* Fix up the error handling a bit

* Simplify imports
2019-10-17 14:46:10 -05:00
Tagan Hoyle
7b3073149c Refactor [wordpress] downloads and add interval to theme downloads (#4180)
Refactor wordpress downloads service
Also add interval for theme downloads
2019-10-15 19:29:00 +01:00
Caleb Cartwright
8b95cdc2aa refactor: honor build qualifiers in version comparisons (#4173) 2019-10-14 12:43:55 -05:00
Caleb Cartwright
13d1cbe0f9 tests: fix service test for ubuntu (#4174) 2019-10-14 18:13:10 +02:00
Pierre-Yves B
0439e10ac8 Support [JenkinsCoverage] through the Code Coverage API plugin (#4168) 2019-10-12 18:24:29 +01:00
Marcin Mielnicki
4c159eff00 Support for XPath functions in [dynamicxml] badge (#4153)
* Support XPath query with type convertion

* Support XPath query with node function

* Parametrized tests for transform function

* Handle unusual values returned by 'select'
2019-10-12 17:23:17 +02:00
netsgnut
76665f6b42 Allow [librariesio] badges referencing scoped npm package (#4025) (#4151)
* Allow libraries.io badges referencing scoped npm package (#4025)

* Set timeout of all libraries.io test units to 10s
2019-10-11 08:56:01 -05:00
Caleb Cartwright
65f66642dd fix type errors in [DynamicXml] service (#4041)
* fix: type errors in DynamicXml service

* tests: add more tests for DynamicXml

* tests: another DynamicXml service test
2019-10-08 15:48:43 -05:00
chris48s
a66e4f9e10 change query for fork count (#4150) 2019-10-08 19:15:29 +01:00
Caleb Cartwright
b05f0e8d0b Update service tests for [Scrutinizer Microbadger jsDelivr] (#4145)
* fix: support scrutinizer branches with only failed builds

* tests: increase timeout for microbadger tests

* tests: increase timeouts for jsdelivr and microbadger tests
2019-10-07 07:19:07 -05:00
Caleb Cartwright
65b54e0420 handle missing license key in [aur] (#4143)
* fix: handle missing license key in aur

* refactor: improve missing license message
2019-10-06 09:17:49 -05:00
seetd
f5823241f2 Add documentation for Discord badge (#3952) (#4117) 2019-10-04 22:10:52 +01:00
Paul Melnikow
76cb943858 Add a GitHub project badge for Hacktoberfest [GithubHacktoberfest] (#4109) 2019-10-02 22:05:56 -04:00
Paul Melnikow
33a6c5398d Fix an undefined variable in [GithubPackageJson] (#4113)
* Fix an undefined variable in [GithubPackageJson]

Make sure this gets linted in the future.

* Run prettier
2019-10-02 21:26:12 +00:00
Paul Melnikow
a5b2f5436c Optimize [GithubIssues] using GraphQL (#4107)
While playing around with a badge for Hacktoberfest I noticed the GitHub Issues badge fetches a huge amount of JSON to render just the total count. There doesn’t seem to be a way to limit the response size through the REST API, so I thought I’d switch this to use GraphQL instead.
2019-10-02 19:34:14 +00:00
Paul Melnikow
e8d49f2504 Add dependency badge for Pipenv applications [GithubPipenv] (#4096)
I recently published https://github.com/metabolize/rq-dashboard-on-heroku and want to add badges to show the locked version of Python and rq-dashboard, the main dependency it’s wrapping.

This is along the lines of #2259, which was for package.json-based applications, and also included some discussion of a Python application that used `requirements.txt`. It’s useful for showing the pinned version of any dependency in a Python application that uses a lockfile.

In the future, as an alternative to reading Pipfile.lock, I could see expanding this to read Pipfile. However for my purposes I prefer to show the locked dependency, since that’s the version that a user of my package would actually get if they ran it on Heroku.
2019-10-02 15:24:14 -04:00
Pierre-Yves B
157a6180b2 Make search work with category names (#4103) 2019-10-02 20:03:59 +01:00
seetd
a865b81acb fix: allow empty but required resolution property for [Bugzilla] (#4102) (#4106)
* fix: use repos from badges organization for GithubContributors  (#4104)

* fix: allow empty but required resolution property for [Bugzilla] (#4102)
2019-10-02 12:11:40 -05:00
seetd
51d879d7d2 fix: use repos from badges organization for GithubContributors (#4104) (#4105)
Fixes #4104
2019-10-02 00:21:46 -05:00
Caleb Cartwright
645343887e fix: add killed to drone schema (#4099) 2019-09-28 11:46:32 -05:00
Caleb Cartwright
90f8ffce9e tests: add endpoint test for #3780 (#4067) 2019-09-23 23:51:43 -04:00
chris48s
c762d971b4 upgrade Joi and related packages (#4060)
* update dependencies

* (core) children --> keys

* (core) fix/update BaseService validate

* (core) update error messages in tests

* (core) only Joi.attempt if we've got a Joi schema

* (core) allow 'expected' to be a regex

* (services) pass 2 schema to .alternatives()

* (services) functions --> Joi schema

* (services) update expected error message

* (services) explicit check for color: undefined

* re-bump joi

* (services) wrap another regex

* (core/services) remove use of array arguments

* (core/services) when --> conditional

* (services) remove more array arguments

* fix spelling in var name

* DRY up sonar helper
2019-09-23 17:36:56 +01:00
Caleb Cartwright
d18d4218fc support basic auth with just pass token (#4063)
* feat: support basic auth with token

* refactor: change param name
2019-09-22 11:14:01 -05:00
Pierre-Yves B
b73d544a67 Add [MicrobadgerSize] documentation (#4038) 2019-09-17 20:18:49 +01:00
Caleb Cartwright
e6be6bdb30 fix(TwitterFollow): encode usernames for links (#4036) 2019-09-17 00:44:07 +00:00
Caleb Cartwright
233c394fe8 move [MavenMetadata] url to query param (#4021)
* refactor: move MavenMetadata url to query param

* refactor(MavenMetadata): rename query param, update redirect pattern
2019-09-17 00:34:11 +00:00
Caleb Cartwright
b80070985c switch [TeamCity] to pattern and move url to query param (#4022)
* refactor(TeamCity): switch to pattern & move url to query param

* refactor(TeamCity): rename query param
2019-09-16 23:59:04 +00:00
Paul Melnikow
311ccc8834 Fix [CodefactorGrade] again (#4034)
This looks like a case of confusing `Joi.allow()` with `Joi.valid()`.

`Joi.valid(...['A', 'A-']).validate('-')` throws an error but `Joi.allow(...['A', 'A-']).validate('-')` allows it through.

Closes #4033
2019-09-16 17:37:54 +00:00
Caleb Cartwright
69a57fa8dd move [Jira] hostname to query param (#3990)
* refactor: convert Jira host to query param

* tests: fix Jira auth tests

* refactor(Jira): change query param name
2019-09-16 14:38:28 +00:00
Caleb Cartwright
51d864efc1 move [Discourse] url to query param (#4020)
* refactor: switch Discourse url to query param

* tests: fix e2e test with Discourse example

* refactor(Discourse): change query param name to server

* tests: update e2e test with new discourse param name
2019-09-16 02:15:19 +00:00
Caleb Cartwright
db0ebf1e6a move [Twitter] url to query param (#4027)
* refactor(TwitterUrl): move url to query param

* refactor(Twitter): update suggestion endpoint

* tests: update twitter suggestion int tests

* chore: fix typo in suggestion int test
2019-09-16 02:07:24 +00:00
Caleb Cartwright
d1c0165afd refactor(Website): move url to query param (#4028) 2019-09-16 01:19:55 +00:00
Caleb Cartwright
76b2e2634a fix(GitHubDownloads): type error on latest with pre-downloads (#4030) 2019-09-16 01:08:39 +00:00
Caleb Cartwright
9fe4d739b0 fix [LiberapayGoal] type error when no receiving data exists (#4029)
* fix(LiberapayGoal): type error when no receiving data exists

* chore: prettify things
2019-09-16 00:39:34 +00:00
Paul Melnikow
0434b9b3ba Fix TypeError for invalid [Debian] response (#4023)
Fix #4019
2019-09-15 17:13:21 +00:00
Paul Melnikow
23ac2b0318 Fix AssertionError in [DynamicJson] when a non-object is in the JSON (#4024)
Closes #4018
2019-09-15 17:05:02 +00:00
Paul Melnikow
fe34bcf28b Throw explicit error on invalid [codefactorgrade] color (#4015)
It’s hard to understand how #3813 is persisting. The schema should reject keys not in the object… it’s very puzzling.

This replaces the code used to get the color with a function call that throws an explicit error when the key is missing. It should at least make it clear what the key value is when this fails in the future.
2019-09-14 11:24:57 -05:00
Honza Hommer
22d713c29b Support custom [Packagist] server (#3986)
* feat(packagist): add custom server query param

* chore(docs): packagist docs tweak

* feat(packagist): custom server downloads badge

* test(packagist): fix custom server tests
2019-09-13 14:38:45 -05:00
Sandro Rodrigues
fa0a25cf0a Added [SecurityHeaders] badge (#3958)
* Added security headers service.

* Small improvements from provided feedback.

* Fixed failing tests.

* Removed grade condition on render method.

* Changed protocol and path from pattern to querystring
2019-09-10 20:54:49 -05:00
Andy Li
4b9053d2d5 add [twitch] user status badge (#3683)
* add /twitch/status/:user badge

* update comments

* use a proper schema for the Twitch API calls

* use a token to make Twitch api calls

* fix handling of rate-limit error and bad token error

* [twitch] get a token as soon as creating a Twitch service

* [twitch] start both requests to users and stream before awaiting

* [twitch] set a timeout to replace the token before it expires

* [twitch] use authHelper

* [twitch] skip tests when no credentials

* [twitch] add one more status test

* twitch: do not check whether a user exists
2019-09-09 16:41:32 -05:00
Pierre-Yves B
c6d52e40b8 Fix [Scrutinizer] error when using default branch without analysis data (#3962) 2019-09-08 21:09:00 +00:00
chris48s
b3be4d94d5 require key 'latest' to exist (#3956) 2019-09-07 20:03:41 +00:00
chris48s
873172522f [dynamicxml] wrap xpath errors (#3955)
Closes #3796
2019-09-07 13:02:27 -04:00
Anand Chowdhary
58a5239e18 Add [Netlify] (fixed #3129) (#3953)
* Add Netlify (fixed #3129)

* Update services/netlify/netlify.service.js

Co-Authored-By: ExE Boss <3889017+ExE-Boss@users.noreply.github.com>

* Remove pattern from return statement

Co-Authored-By: ExE Boss <3889017+ExE-Boss@users.noreply.github.com>

* Add Netlify namedLogo to return statement

Co-Authored-By: ExE Boss <3889017+ExE-Boss@users.noreply.github.com>

* Change label from "build" to "netlify" in test

Co-Authored-By: Caleb Cartwright <calebcartwright@users.noreply.github.com>

* Change label from "build" to "netlify" in test

Co-Authored-By: Caleb Cartwright <calebcartwright@users.noreply.github.com>

* test(netlify): Fix failing tests

Co-Authored-By: ExE Boss <3889017+ExE-Boss@users.noreply.github.com>

* Fix "netlify" spelling in label

Co-Authored-By: ExE Boss <3889017+ExE-Boss@users.noreply.github.com>

* Use const instead of let for result

Co-Authored-By: ExE Boss <3889017+ExE-Boss@users.noreply.github.com>

* Change "project not found" to "not found"

* Use unknown as fallback response

Co-Authored-By: ExE Boss <3889017+ExE-Boss@users.noreply.github.com>

* Add documentation for project ID, remove commented part

* Fix documentation key in example
2019-09-06 12:21:17 -05:00
Pierre-Yves B
4190609d1b Handle missing Symfony Insight grade gracefully (#3933) 2019-09-03 09:49:00 +01:00