-
Bug
-
Resolution: Fixed
-
Minor
-
None
-
Ubuntu 11.10/Openjdk/jenkins 1.452
Using email-ext plugin, and set use groovy html template
- Content Type : HTML
- Default content ${SCRIPT}
When the build is SUCCESS, it is still use yellow.gif instead of blue.git
Problem:
<%= build.result == 'SUCCESS' ? "blue.gif" : build.result == 'FAILURE' ? 'red.gif' : 'yellow.gif' %>" />
build.result is not string, so the compare is false always.
Solution:
<%= build.result.toString() == 'SUCCESS' ? "blue.gif" : build.result.toString() == 'FAILURE' ? 'red.gif' : 'yellow.gif' %>" />
I push the code into github