This plugin allows to customize commit status for unstable builds. By default github-branch-source-plugin
marks unstable builds' commit status as failed making it impossible to have test reporting enabled for failing tests aka unstable builds leaving only two options:
- Fix the builds -- might not always be possible / feasible / priority.
- Do not report -- leads to loss of useful test metrics over time, and reporting can help prevent and implement the minimal "do not break anything new" rule.
This was implemented by Github Branch Source trait.
After installing go to the job configuration. Under "Branch sources" -> "GitHub" -> "Behaviors" click "Add" and select "Custom Github Commit Status For Unstable Builds" from the dropdown menu. Then you can select the checkbox if you want to mark unstable builds' commit statuses as success, or deselect it for default behavior.
mvn verify
mvn hpi:run