[Copr] Add build status badge#11940
Open
LuxologyGG wants to merge 4 commits into
Open
Conversation
Contributor
|
8121c83 to
4d12e2c
Compare
Implements a build badge for the Fedora Copr build system using the Copr API v3 package endpoint. Closes badges#6078
Move fetch method before transform to satisfy ESLint sort-class-members rule.
1ce9ed7 to
fcba49b
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Adds a new build status badge for the Fedora Copr build system.
Closes #6078
Example
Badge endpoint
/copr/build/:owner/:project/:packageOptional
serverquery parameter defaults tohttps://copr.fedorainfracloud.org.API rate limits
The Copr API v3 documentation does not document request rate limits for read-only endpoints. This badge issues one GET per render to
/api_3/packagewithwith_latest_build=True.Implementation
services/copr/copr.service.js— fetches latest build state from Copr API v3services/copr/copr.service.spec.js— unit tests for URL, transform, and render logicservices/copr/copr.tester.js— live and mocked service testsChecklist
services/copr/copr.service.js)services/copr/copr.service.spec.js)services/copr/copr.tester.js)npm run lint(0 errors)