Skip to content

Commit

Permalink
[JENKINS-9203] Added integration test case that fails under 1.398 but…
Browse files Browse the repository at this point in the history
… not under 1.397
  • Loading branch information
redsolo committed Apr 5, 2011
1 parent a065565 commit 7485913
Show file tree
Hide file tree
Showing 2 changed files with 27 additions and 0 deletions.
@@ -0,0 +1,27 @@
package hudson.plugins.build_timeout;

import hudson.model.FreeStyleBuild;
import hudson.model.FreeStyleProject;
import hudson.model.Result;
import hudson.tasks.BuildWrapper;
import hudson.tasks.test.AbstractTestResultAction;

import org.jvnet.hudson.test.Bug;
import org.jvnet.hudson.test.HudsonTestCase;
import org.jvnet.hudson.test.recipes.LocalData;

public class BuildTimeoutWrapperIntegrationTest extends HudsonTestCase {

@Bug(9203)
@LocalData
public void testIssue9203() throws Exception {
FreeStyleProject project = (FreeStyleProject) hudson.getItem("9203");

// Force a timeout of 1, plugin will not accept less than 3 minutes.
BuildTimeoutWrapper buildWrapper = (BuildTimeoutWrapper) project.getBuildWrappersList().get(0);
buildWrapper.timeoutMinutes = 1;

FreeStyleBuild build = project.scheduleBuild2(0).get();
assertBuildStatus(Result.FAILURE, build);
}
}
Binary file not shown.

0 comments on commit 7485913

Please sign in to comment.