Skip to content

Commit

Permalink
[FIXED JENKINS-30395] Occasional ClosedByInterruptException.
Browse files Browse the repository at this point in the history
(cherry picked from commit aaa71d4)
  • Loading branch information
jglick authored and olivergondza committed Sep 29, 2015
1 parent c110ccc commit c6c8836
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion test/src/main/java/org/jvnet/hudson/test/JenkinsRule.java
Expand Up @@ -190,6 +190,7 @@
import org.junit.runner.Description;
import org.junit.runners.model.FrameworkMethod;
import org.junit.runners.model.Statement;
import java.nio.channels.ClosedByInterruptException;

This comment has been minimized.

Copy link
@KostyaSha

KostyaSha Oct 14, 2015

Member

seems this import in wrong order

import org.jvnet.hudson.test.recipes.Recipe;
import org.jvnet.hudson.test.rhino.JavaScriptDebugger;
import org.kohsuke.stapler.ClassDescriptor;
Expand Down Expand Up @@ -1668,7 +1669,11 @@ void resolveDependencies() throws Exception {

File dst = new File(home, "plugins/" + artifactId + ".jpi");
if(!dst.exists() || dst.lastModified()!=dependencyJar.lastModified()) {
FileUtils.copyFile(dependencyJar, dst);
try {
FileUtils.copyFile(dependencyJar, dst);
} catch (ClosedByInterruptException x) {
throw new AssumptionViolatedException("copying dependencies was interrupted", x);
}
}
}
}
Expand Down

0 comments on commit c6c8836

Please sign in to comment.