JAMES-2186 Fix recuring failing test

Project: http://git-wip-us.apache.org/repos/asf/james-project/repo
Commit: http://git-wip-us.apache.org/repos/asf/james-project/commit/7eb65cfa
Tree: http://git-wip-us.apache.org/repos/asf/james-project/tree/7eb65cfa
Diff: http://git-wip-us.apache.org/repos/asf/james-project/diff/7eb65cfa

Branch: refs/heads/master
Commit: 7eb65cfa42ca77177b879f756aa423a69f96e7e5
Parents: 3966153
Author: benwa <btell...@linagora.com>
Authored: Fri Oct 20 09:10:35 2017 +0700
Committer: Matthieu Baechler <matth...@apache.org>
Committed: Fri Oct 20 12:34:52 2017 +0200

----------------------------------------------------------------------
 .../src/test/java/org/apache/james/jmap/ContainerTest.java      | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/james-project/blob/7eb65cfa/server/protocols/jmap-integration-testing/jmap-integration-testing-common/src/test/java/org/apache/james/jmap/ContainerTest.java
----------------------------------------------------------------------
diff --git 
a/server/protocols/jmap-integration-testing/jmap-integration-testing-common/src/test/java/org/apache/james/jmap/ContainerTest.java
 
b/server/protocols/jmap-integration-testing/jmap-integration-testing-common/src/test/java/org/apache/james/jmap/ContainerTest.java
index 99f2d89..a403ed1 100644
--- 
a/server/protocols/jmap-integration-testing/jmap-integration-testing-common/src/test/java/org/apache/james/jmap/ContainerTest.java
+++ 
b/server/protocols/jmap-integration-testing/jmap-integration-testing-common/src/test/java/org/apache/james/jmap/ContainerTest.java
@@ -29,12 +29,15 @@ import org.apache.http.client.utils.URIBuilder;
 import org.apache.james.util.streams.SwarmGenericContainer;
 import org.junit.Rule;
 import org.junit.Test;
+import org.testcontainers.containers.wait.HttpWaitStrategy;
 
 public class ContainerTest {
 
     @Rule
     public SwarmGenericContainer container = new 
SwarmGenericContainer("nginx:1.7.1")
-            .withAffinityToContainer();
+        .withAffinityToContainer()
+        .withExposedPorts(80)
+        .waitingFor(new HttpWaitStrategy().forStatusCode(200));
 
     @Test
     public void containerShouldBeReachableOnExposedPort() throws IOException, 
URISyntaxException {


---------------------------------------------------------------------
To unsubscribe, e-mail: server-dev-unsubscr...@james.apache.org
For additional commands, e-mail: server-dev-h...@james.apache.org

Reply via email to