Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Merge pull request #19 from krische/master
[JENKINS-25738] added getResult() as a whitelisted method
  • Loading branch information
ikedam committed Dec 19, 2014
2 parents defcf33 + ec6cd32 commit 3535afc
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 0 deletions.
Expand Up @@ -154,6 +154,10 @@ public void addWarningBadge(String text) {
public void addErrorBadge(String text) {
build.getActions().add(GroovyPostbuildAction.createErrorBadge(text));
}

@Whitelisted
public String getResult() { return build.getResult().toString(); }

@Whitelisted
public void removeBadges() {
List<Action> actions = build.getActions();
Expand Down
Expand Up @@ -12,6 +12,7 @@
<li><code>logContains(regexp)</code> - returns true if the build log file contains a line matching <i>regexp</i>.</li>
<li><code>getMatcher(file, regexp)</code> - returns a java.util.regex.Matcher for the first occurrence of <i>regexp</i> in the given file.</li>
<li><code>getLogMatcher(regexp)</code> - returns a java.util.regex.Matcher for the first occurrence of <i>regexp</i> in the build log file.</li>
<li><code>getResult()</code> - returns the current build result.</li>
<P/>
<li><code>addShortText(text)</code> - puts a badge with a short text, using the default format.</li>
<li><code>addShortText(text, color, background, border, borderColor)</code> - puts a badge with a short text, using the specified format.</li>
Expand Down

0 comments on commit 3535afc

Please sign in to comment.