Skip to content
This repository has been archived by the owner on Sep 16, 2024. It is now read-only.

Commit

Permalink
#87 Added another test case
Browse files Browse the repository at this point in the history
  • Loading branch information
rjrudin committed Mar 15, 2016
1 parent 17fb259 commit 1a44c21
Showing 1 changed file with 26 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -54,4 +54,30 @@ public void odbcAndXdbcServers() {
assertFalse(mgr.exists("sample-app-odbc"));
assertFalse(mgr.exists("sample-app"));
}

@Test
public void ignoreOdbcServer() {
appConfig.setConfigDir(new ConfigDir(new File("src/test/resources/sample-app/other-servers")));

ServerManager mgr = new ServerManager(manageClient);

DeployOtherServersCommand c = new DeployOtherServersCommand();
c.setIgnoreFilenames("odbc-server.json");
initializeAppDeployer(c);

appConfig.getCustomTokens().put("%%ODBC_PORT%%", "8048");
appConfig.getCustomTokens().put("%%XDBC_PORT%%", "8049");
appDeployer.deploy(appConfig);

final String message = "Both the ODBC and REST API server files should have been ignored";
assertTrue(mgr.exists("sample-app-xdbc"));
assertFalse(message, mgr.exists("sample-app-odbc"));
assertFalse(message, mgr.exists("sample-app"));

appDeployer.undeploy(appConfig);

assertFalse(mgr.exists("sample-app-xdbc"));
assertFalse(mgr.exists("sample-app-odbc"));
assertFalse(mgr.exists("sample-app"));
}
}

0 comments on commit 1a44c21

Please sign in to comment.