JAMES-1717 Solve concurrency issue linked to the mailQueue in Vacation 
integration tests


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

Branch: refs/heads/master
Commit: 5e858b61017bda44950e12d8333f4ac03cc2d341
Parents: e48e3a6
Author: Benoit Tellier <btell...@linagora.com>
Authored: Tue May 31 17:09:32 2016 +0700
Committer: Matthieu Baechler <matthieu.baech...@linagora.com>
Committed: Tue May 31 18:10:56 2016 +0200

----------------------------------------------------------------------
 .../test/java/org/apache/james/jmap/VacationIntegrationTest.java  | 3 +++
 1 file changed, 3 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/james-project/blob/5e858b61/server/protocols/jmap-integration-testing/jmap-integration-testing-common/src/test/java/org/apache/james/jmap/VacationIntegrationTest.java
----------------------------------------------------------------------
diff --git 
a/server/protocols/jmap-integration-testing/jmap-integration-testing-common/src/test/java/org/apache/james/jmap/VacationIntegrationTest.java
 
b/server/protocols/jmap-integration-testing/jmap-integration-testing-common/src/test/java/org/apache/james/jmap/VacationIntegrationTest.java
index 5686c69..9e96044 100644
--- 
a/server/protocols/jmap-integration-testing/jmap-integration-testing-common/src/test/java/org/apache/james/jmap/VacationIntegrationTest.java
+++ 
b/server/protocols/jmap-integration-testing/jmap-integration-testing-common/src/test/java/org/apache/james/jmap/VacationIntegrationTest.java
@@ -211,6 +211,9 @@ public abstract class VacationIntegrationTest {
         // User 2 matth...@mydomain.tld sends User 1 a mail
         String user2OutboxId = getOutboxId(user2AccessToken);
         sendMail(user2AccessToken, user2OutboxId, "user|inbox|1");
+        // Wait user 1 to receive the eMail before reset of vacation
+        calmlyAwait.atMost(10, TimeUnit.SECONDS)
+            .until(() -> isTextMessageReceived(user1AccessToken, 
getInboxId(user1AccessToken), ORIGINAL_MESSAGE_TEXT_BODY, USER_2, USER_1));
 
         // When
         // User 1 b...@mydomain.tld resets a Vacation on its account


---------------------------------------------------------------------
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