Skip to content

Commit

Permalink
Merge pull request #177 from abayer/jenkins-47064
Browse files Browse the repository at this point in the history
[JENKINS-47064] Verify fix for BooleanClosureWrapper
  • Loading branch information
svanoort committed Sep 27, 2017
2 parents 41ac59c + c482e6f commit 1988c8f
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 1 deletion.
2 changes: 1 addition & 1 deletion pom.xml
Expand Up @@ -67,7 +67,7 @@
<git-plugin.version>3.1.0</git-plugin.version>
<workflow-support-plugin.version>2.14</workflow-support-plugin.version>
<scm-api-plugin.version>2.0.8</scm-api-plugin.version>
<groovy-cps.version>1.19</groovy-cps.version>
<groovy-cps.version>1.20</groovy-cps.version>
</properties>
<dependencies>
<dependency>
Expand Down
Expand Up @@ -277,4 +277,12 @@ public void rhsOfDeclarationSandboxedInCPS() throws Exception {
jenkins.assertBuildStatus(Result.FAILURE, b);
jenkins.assertLogContains("org.jenkinsci.plugins.scriptsecurity.sandbox.RejectedAccessException: Scripts not permitted to use staticMethod jenkins.model.Jenkins getInstance", b);
}

@Issue("JENKINS-47064")
@Test
public void booleanClosureWrapperFromDGM() throws Exception {
WorkflowJob job = jenkins.jenkins.createProject(WorkflowJob.class, "p");
job.setDefinition(new CpsFlowDefinition("assert ['a', 'b'].every { sleep 1; return it != null }\n", true));
jenkins.buildAndAssertSuccess(job);
}
}

0 comments on commit 1988c8f

Please sign in to comment.