Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Jenkins GitHub Pull Request Builder - Status Message

I have set up Jenkins to use the GitHub pull request builder. It's working great! Except one little thing. My test suite creates HTML Reports (which I have beautifully posted using the HTML result poster plugin) but I can't seem to change the status message that gets posted to GitHub. My commits all get marked like:

An image of the status of a successful test run, with a status message of Build finished.  No test results found.

The status of the commit gets updated properly, but the message part always says "Build finished. No test results found."

I can't seem to figure out how to change this message based on the status of the test suite. So, basically the only feedback I'm getting is the exit status of my shell script. This script does all of the building, testing, and handling of results, etc. This is reasonably acceptable in the event of a pass, but in the event of a failure, this message could be much more helpful! Even just knowing whether it was a build failure vs. a test suite failure would be nice, so then I can adequately verbally abuse the person who made the pull request :).

Everything else is working so good, that I can't figure out what seems like a trivial change is driving me crazy! Any ideas?

like image 324
ChrisCM Avatar asked Jun 23 '15 20:06

ChrisCM


People also ask

How do I know if my pull request was accepted?

If it's merged, then it's accepted. If it's closed and not merged it may be rejected.


1 Answers

FWIW, the logic was added here: https://github.com/janinko/ghprb/commit/ffbc581d2712d6b99b9c6d0b081d7895a5ee8039

I believe you just need to generate JUnit formatted test output, and you may or may not need to ad a post-build step to publish the JUnit XML output.

like image 194
tvon Avatar answered Oct 26 '22 23:10

tvon