Skip to content

Commit

Permalink
fixed tests
Browse files Browse the repository at this point in the history
  • Loading branch information
christiangoerdes committed Mar 14, 2024
1 parent a621384 commit 741dd07
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@
import com.predic8.membrane.examples.tests.loadbalancing.Loadbalancing1StaticTest;
import com.predic8.membrane.examples.tests.loadbalancing.Loadbalancing3ClientTest;
import com.predic8.membrane.examples.tests.loadbalancing.Loadbalancing5MultipleTest;
import com.predic8.membrane.examples.tests.log.AccessLogTest;
import com.predic8.membrane.examples.tests.message_transformation.Json2XmlTest;
import com.predic8.membrane.examples.tests.message_transformation.TransformationUsingJavascriptTest;
import com.predic8.membrane.examples.tests.message_transformation.Xml2JsonTest;
Expand Down Expand Up @@ -66,6 +67,9 @@
XMLValidationTest.class,
SampleSoapServiceTest.class,

// Logging
AccessLogTest.class,

// Transformation
Xml2JsonTest.class,
Json2XmlTest.class,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ protected String getExampleDirName() {
@Test
void testConsole() throws Exception {
try (var process = startServiceProxyScript()) {
var console = new WaitableConsoleEvent(process, p -> p.equals("127.0.0.1 \"GET / HTTP/1.1\" 200 0 [application/json]"));
var console = new WaitableConsoleEvent(process, p -> p.contains("\"GET / HTTP/1.1\" 200 0 [application/json]"));
getAndAssert200("http://localhost:2000");
assertTrue(console.occurred());
}
Expand All @@ -44,6 +44,6 @@ void testRollingFile() throws Exception {
try (var ignore = startServiceProxyScript()) {
getAndAssert200("http://localhost:2000");
}
assertContains("127.0.0.1 \"GET / HTTP/1.1\" 200 0 [application/json]", readFile("access.log"));
assertContains("\"GET / HTTP/1.1\" 200 0 [application/json]", readFile("access.log"));
}
}

0 comments on commit 741dd07

Please sign in to comment.