Ignoring LauncherCommandTests.
Similar tests exist in DeployerThreadTests. See gh-27
This commit is contained in:
@@ -19,6 +19,7 @@ package org.springframework.cloud.launcher.cli;
|
||||
import static org.hamcrest.CoreMatchers.containsString;
|
||||
import static org.junit.Assert.assertThat;
|
||||
|
||||
import org.junit.Ignore;
|
||||
import org.junit.Rule;
|
||||
import org.junit.Test;
|
||||
|
||||
@@ -31,12 +32,14 @@ public class LauncherCommandTests {
|
||||
public OutputCapture output = new OutputCapture();
|
||||
|
||||
@Test
|
||||
@Ignore("See DeployerThreadTests for similar functionality")
|
||||
public void testCreateClassLoaderAndListDeployables() throws Exception {
|
||||
new LauncherCommand().run("--list");
|
||||
assertThat(output.toString(), containsString("configserver"));
|
||||
}
|
||||
|
||||
@Test
|
||||
@Ignore("See DeployerThreadTests for similar functionality")
|
||||
public void testNonOptionArgsPassedDown() throws Exception {
|
||||
new LauncherCommand().run("--list", "--", "--spring.profiles.active=test");
|
||||
assertThat(output.toString(), containsString("foo"));
|
||||
|
||||
@@ -87,8 +87,12 @@ public class DeployerThread extends Thread {
|
||||
}
|
||||
|
||||
private void quiet() {
|
||||
LogbackLoggingSystem.get(ClassUtils.getDefaultClassLoader()).setLogLevel("ROOT",
|
||||
LogLevel.OFF);
|
||||
try {
|
||||
LogbackLoggingSystem.get(ClassUtils.getDefaultClassLoader()).setLogLevel("ROOT",
|
||||
LogLevel.OFF);
|
||||
} catch (Exception e) {
|
||||
logger.error("Unable to turn of ROOT logger for quiet()", e);
|
||||
}
|
||||
}
|
||||
|
||||
private void list() {
|
||||
|
||||
@@ -36,4 +36,10 @@ public class DeployerThreadTests {
|
||||
assertThat(output.toString(), containsString("configserver"));
|
||||
}
|
||||
|
||||
|
||||
@Test
|
||||
public void testNonOptionArgsPassedDown() throws Exception {
|
||||
new DeployerThread(DeployerThread.class.getClassLoader(), "--launcher.list=true", "--spring.profiles.active=test").run();
|
||||
assertThat(output.toString(), containsString("foo"));
|
||||
}
|
||||
}
|
||||
|
||||
@@ -0,0 +1,9 @@
|
||||
spring:
|
||||
cloud:
|
||||
launcher:
|
||||
deployables:
|
||||
foo:
|
||||
coordinates: com.example:foo:0.0.1-SNAPSHOT
|
||||
port: 8000
|
||||
waitUntilStarted: true
|
||||
order: -200
|
||||
Reference in New Issue
Block a user