|
|
|
@ -48,7 +48,6 @@ import org.junit.runners.Parameterized;
|
|
|
|
|
import org.junit.runners.Parameterized.Parameters;
|
|
|
|
|
|
|
|
|
|
import org.springframework.boot.ansi.AnsiColor;
|
|
|
|
|
import org.springframework.boot.testutil.Matched;
|
|
|
|
|
|
|
|
|
|
import static org.assertj.core.api.Assertions.assertThat;
|
|
|
|
|
import static org.hamcrest.Matchers.containsString;
|
|
|
|
@ -285,7 +284,14 @@ public class SysVinitLaunchScriptIT {
|
|
|
|
|
|
|
|
|
|
private Condition<String> coloredString(AnsiColor color, String string) {
|
|
|
|
|
String colorString = ESC + "[0;" + color + "m" + string + ESC + "[0m";
|
|
|
|
|
return Matched.by(containsString(colorString));
|
|
|
|
|
return new Condition<String>() {
|
|
|
|
|
|
|
|
|
|
@Override
|
|
|
|
|
public boolean matches(String value) {
|
|
|
|
|
return containsString(colorString).matches(value);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
};
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
private String extractPid(String output) {
|
|
|
|
|