Skip to content
This repository has been archived by the owner on Dec 15, 2021. It is now read-only.

Commit

Permalink
Merge pull request #257 from jglick/RejectedAccessException-JENKINS-3…
Browse files Browse the repository at this point in the history
…1701

[JENKINS-31701] Verifying fix in reported context
  • Loading branch information
jglick committed Jan 21, 2016
2 parents 527cbb8 + 1da7340 commit 3aaaabe
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 1 deletion.
Expand Up @@ -39,6 +39,7 @@
import org.junit.Test;
import org.junit.runners.model.Statement;
import org.jvnet.hudson.test.BuildWatcher;
import org.jvnet.hudson.test.Issue;
import org.jvnet.hudson.test.RestartableJenkinsRule;

public class SleepStepTest {
Expand Down Expand Up @@ -70,4 +71,15 @@ public class SleepStepTest {
});
}

@Issue("JENKINS-31701")
@Test public void sleepInsideNode() {
r.addStep(new Statement() {
@Override public void evaluate() throws Throwable {
WorkflowJob p = r.j.jenkins.createProject(WorkflowJob.class, "p");
p.setDefinition(new CpsFlowDefinition("node {sleep 1}", true));
r.j.assertBuildStatusSuccess(p.scheduleBuild2(0));
}
});
}

}
2 changes: 1 addition & 1 deletion pom.xml
Expand Up @@ -72,7 +72,7 @@
<dependency>
<groupId>org.jenkins-ci.plugins</groupId>
<artifactId>script-security</artifactId>
<version>1.15</version>
<version>1.16</version>
</dependency>
<dependency>
<groupId>org.jenkins-ci.plugins</groupId>
Expand Down

0 comments on commit 3aaaabe

Please sign in to comment.