-
Notifications
You must be signed in to change notification settings - Fork 38
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add subscriber for check run event in order to handle rerun request #25
Conversation
src/main/java/io/jenkins/plugins/checks/github/CheckRunGHEventSubscriber.java
Show resolved
Hide resolved
* Get branch name from {@link JSONObject}. | ||
* | ||
* This method will be replaced by {@link CheckRunGHEventSubscriber#getBranchName(GHEventPayload.CheckRun, String)} | ||
* after the release of github--api-plugin 1.116. The github-api has already released 1.116 and make |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
so do we need this method? seems like it should be available?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this method is available, but using the object from github-api is better since we don't have to parse the json again, and more safe.
the github-api has released 1.116, may just need to wait two or three days, the github-api-plugin will follow up
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
kk
The next step: in checks-api, add the "rerun" action in the listener for the main build when completed. |
src/main/java/io/jenkins/plugins/checks/github/CheckRunGHEventSubscriber.java
Outdated
Show resolved
Hide resolved
Codecov Report
@@ Coverage Diff @@
## master #25 +/- ##
============================================
+ Coverage 77.33% 79.32% +1.98%
- Complexity 96 112 +16
============================================
Files 7 8 +1
Lines 300 353 +53
Branches 33 39 +6
============================================
+ Hits 232 280 +48
- Misses 48 53 +5
Partials 20 20
Continue to review full report at Codecov.
|
For the request payload example, see https://github.com/jenkinsci/github-checks-plugin/blob/8273ee1bc151e0b1b94bfa9a5a9d8e88c3e29b7f/src/test/resources/io/jenkins/plugins/checks/github/CheckRunGHEventSubscriberTest/check-run-event-with-rerun-action.json