Skip to content

Commit

Permalink
[JENKINS-32273] CLI exit codes changed as of #1997 in 1.649.
Browse files Browse the repository at this point in the history
  • Loading branch information
jglick committed Apr 29, 2016
1 parent 94af2e8 commit 9f3f352
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions test/src/test/java/hudson/cli/GetNodeCommandTest.java
Expand Up @@ -97,11 +97,11 @@ public class GetNodeCommandTest {
public void getNodeShouldFailForMaster() throws Exception {
CLICommandInvoker.Result result = command.authorizedTo(Computer.EXTENDED_READ, Jenkins.READ).invokeWithArgs("");
assertThat(result.stderr(), containsString("No such node ''"));
assertThat(result, failedWith(-1));
assertThat(result, failedWith(3));
assertThat(result, hasNoStandardOutput());
result = command.authorizedTo(Computer.EXTENDED_READ, Jenkins.READ).invokeWithArgs("(master)");
assertThat(result.stderr(), containsString("No such node '(master)'"));
assertThat(result, failedWith(-1));
assertThat(result, failedWith(3));
assertThat(result, hasNoStandardOutput());
}

Expand Down
4 changes: 2 additions & 2 deletions test/src/test/java/hudson/cli/UpdateNodeCommandTest.java
Expand Up @@ -103,11 +103,11 @@ public class UpdateNodeCommandTest {
public void updateNodeShouldFailForMaster() throws Exception {
CLICommandInvoker.Result result = command.authorizedTo(Computer.CONFIGURE, Jenkins.READ).withStdin(Computer.class.getResourceAsStream("node.xml")).invokeWithArgs("");
assertThat(result.stderr(), containsString("No such node ''"));
assertThat(result, failedWith(-1));
assertThat(result, failedWith(3));
assertThat(result, hasNoStandardOutput());
result = command.authorizedTo(Computer.EXTENDED_READ, Jenkins.READ).withStdin(Computer.class.getResourceAsStream("node.xml")).invokeWithArgs("(master)");
assertThat(result.stderr(), containsString("No such node '(master)'"));
assertThat(result, failedWith(-1));
assertThat(result, failedWith(3));
assertThat(result, hasNoStandardOutput());
}

Expand Down

0 comments on commit 9f3f352

Please sign in to comment.