Skip to content
Permalink
Browse files

[JENKINS-19539] Do not (try to) generate coverage information if buil…

…d was aborted
  • Loading branch information...
mabako authored and centic9 committed Sep 11, 2013
1 parent 7d3db62 commit ff22ec06f27171ef4fe2d064c28f22b4f4d16581
@@ -239,7 +239,7 @@ public JacocoBuildAction getPreviousResult() {
b = b.getPreviousBuild();
if(b==null)
return null;
if(b.getResult()== Result.FAILURE)
if(b.getResult()== Result.FAILURE || b.getResult() == Result.ABORTED)
continue;
JacocoBuildAction r = b.getAction(JacocoBuildAction.class);
if(r!=null)
@@ -41,7 +41,7 @@ public String getUrlName() {
*/
public JacocoBuildAction getLastResult() {
for (AbstractBuild<?, ?> b = project.getLastBuild(); b != null; b = b.getPreviousBuild()) {
if (b.getResult() == Result.FAILURE)
if (b.getResult() == Result.FAILURE || b.getResult() == Result.ABORTED)
continue;
JacocoBuildAction r = b.getAction(JacocoBuildAction.class);
if (r != null)
@@ -307,7 +307,7 @@ public boolean perform(AbstractBuild<?,?> build, Launcher launcher, BuildListene
FilePath[] matchedClassDirs = null;
FilePath[] matchedSrcDirs = null;

if (build.getResult().equals(Result.FAILURE)) {
if (build.getResult() == Result.FAILURE || build.getResult() == Result.ABORTED) {
return true;
}

0 comments on commit ff22ec0

Please sign in to comment.
You can’t perform that action at this time.