From 1a5e41bb0fa3cce584dea67b0d431cb62c830a08 Mon Sep 17 00:00:00 2001 From: Esa Laine Date: Wed, 22 Aug 2012 11:14:28 -0400 Subject: [PATCH] add test case for JENKINS-14772 --- .../groovy/hudson/cli/BuildCommandTest.groovy | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/test/src/test/groovy/hudson/cli/BuildCommandTest.groovy b/test/src/test/groovy/hudson/cli/BuildCommandTest.groovy index aeea843a49..deb1531714 100644 --- a/test/src/test/groovy/hudson/cli/BuildCommandTest.groovy +++ b/test/src/test/groovy/hudson/cli/BuildCommandTest.groovy @@ -84,6 +84,22 @@ public class BuildCommandTest extends HudsonTestCase { } + /** + * Tests synchronous execution with retried verbose output + */ + void testSyncWOutputStreaming() { + def p = createFreeStyleProject(); + p.buildersList.add(new Shell("sleep 3")); + + def cli =new CLI(getURL()) + try { + cli.execute(["build","-s","-v","-r","5",p.name]) + assertFalse(p.getBuildByNumber(1).isBuilding()) + } finally { + cli.close(); + } + } + void testParameters() { def p = createFreeStyleProject(); p.addProperty(new ParametersDefinitionProperty([new StringParameterDefinition("key",null)]));