chris48s
13d75e0607
upgrade to prettier 2 ( #5051 )
...
* arrowParens: avoid
* remove trailingComma setting
2020-05-05 21:07:43 +01:00
Caleb Cartwright
5c33c8121c
tests: fix flaky mozilla service tests ( #4321 )
2019-11-12 19:18:09 -06: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
fb2727d22e
tests: make MozillaObservatory service tests more durable ( #3817 )
2019-08-09 15:56:53 -05:00
chris48s
8621fe42d7
Upgrade Joi ( #3505 )
...
* upgrade joi
* find & replace ALL THE THINGS
* update related deps
2019-06-02 21:59:55 +01:00
chris48s
65dba94fa8
Stop calling variables "which"; affects [chocolatey codeclimate conda crates debug gem github mozillaobservatory nuget powershellgallery pub resharper vaadindirectory] ( #3495 )
...
* which --> variant
* which --> alias
* which --> format
* improve param names in codeclimate
* improve param names in github-issue-detail
* update github-issue-detail unit tests
2019-05-28 23:00:12 +01:00
Paul Melnikow
f8aeb56129
Unify order of more services ( #3358 )
...
Ref #3353
2019-04-24 15:08:26 -04:00
Pierre-Yves B
25f8541e5b
JSON format modernisation and _shields_test removal ( #3272 )
...
* Modernised JSON format and removed _shields_test style
* Added logoWidth and labelColor fields to JSON response
* Reinstated and updated comment
* Extended expectBadge to accept Joi schemas for all fields
2019-04-07 18:57:55 +01:00
Paul Melnikow
be95faf347
Tweak examples for observatory, azure devops ( #3169 )
2019-03-06 19:55:42 -06:00
Pierre-Yves B
1f29c22d3d
Migrated most service tests to use new expectBadge ( #3122 )
2019-02-28 21:43:23 +00:00
Paul Melnikow
2d7be31b0c
Validate query params in BaseService ( #3042 )
...
This is a mid-sized PR that adds query param validation to BaseService and updates most of the services which use query param validation to use it. There are a couple minor tweaks I made along the way.
Fix #2676
2019-02-20 22:24:47 -05:00
Paul Melnikow
24bc7bcfc3
Combine some badge examples using drop-downs, tweak some titles ( #3037 )
...
This updates several badges to take advantage of the change from #2882 .
2019-02-18 23:04:25 -05:00
Yves M
ee1a3564f0
Add Mozilla HTTP Observatory badge [MozillaObservatory] ( #2935 )
...
* Begin adding a Mozilla Observatory badge (#2912 )
* Update tests to add `_shields_test` style
* Add grade D and E tests
* Use Shields color scheme
See https://github.com/badges/shields/issues/2912#issuecomment-461692102
Resolves https://github.com/badges/shields/pull/2935#pullrequestreview-201432260
* Fix grade response validation regex
A bit related to https://github.com/badges/shields/pull/2935#pullrequestreview-201430779
* Add the host query param via `qs`
Resolves https://github.com/badges/shields/pull/2935#pullrequestreview-201431030
* Make integration test on `observatory.mozilla.org`
- Use `observatory.mozilla.org` instead of `httpforever.com` which redirects to `observatory.mozilla.org` anyway
- Use Joi to validate response
* Define label using `defaultBadgeData`
Resolves https://github.com/badges/shields/pull/2935#pullrequestreview-201431659
* Use short hand `createServiceTester` function helper in tests
Resolves https://github.com/badges/shields/pull/2935#pullrequestreview-201431898
* Make strict API response validation
See https://github.com/badges/shields/pull/2935#discussion_r255097377
* Use the `POST` API endpoint to trigger new scan
See https://github.com/badges/shields/issues/2912#issuecomment-462064216
* Handle unfinished states
See https://github.com/badges/shields/issues/2912#issuecomment-462064216
* Split in two separate badges, with and without score
See https://github.com/badges/shields/issues/2912#issuecomment-461692102
* Add a `publish` parameter to include the result in public list
See https://github.com/badges/shields/issues/2912#issuecomment-461764463
* Add documentation
* Update tester importer
* Remove redundant example keywords
Resolves https://github.com/badges/shields/pull/2935#discussion_r257086115
* Minor doc update
* Embed `which` parameter in examples
* Remove root path from pattern in examples
Resolves https://github.com/badges/shields/pull/2935#pullrequestreview-204582763 and https://github.com/badges/shields/pull/2935#pullrequestreview-204582728
* Pass missing `which` parameter to render in examples
Resolves https://github.com/badges/shields/pull/2935#discussion_r257525827
2019-02-18 10:11:44 -06:00