ignite-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From sboi...@apache.org
Subject [06/50] [abbrv] ignite git commit: .NET: Fix MessagingTest flakiness
Date Wed, 19 Apr 2017 08:45:47 GMT
.NET: Fix MessagingTest flakiness


Project: http://git-wip-us.apache.org/repos/asf/ignite/repo
Commit: http://git-wip-us.apache.org/repos/asf/ignite/commit/58a8cb25
Tree: http://git-wip-us.apache.org/repos/asf/ignite/tree/58a8cb25
Diff: http://git-wip-us.apache.org/repos/asf/ignite/diff/58a8cb25

Branch: refs/heads/ignite-4929
Commit: 58a8cb2579665c989ea9b08ebebf7b050f4d1405
Parents: 22580e1
Author: Pavel Tupitsyn <ptupitsyn@apache.org>
Authored: Tue Apr 18 16:01:49 2017 +0300
Committer: Pavel Tupitsyn <ptupitsyn@apache.org>
Committed: Tue Apr 18 16:02:36 2017 +0300

----------------------------------------------------------------------
 .../dotnet/Apache.Ignite.Core.Tests/MessagingTest.cs   | 13 ++++++++-----
 1 file changed, 8 insertions(+), 5 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/ignite/blob/58a8cb25/modules/platforms/dotnet/Apache.Ignite.Core.Tests/MessagingTest.cs
----------------------------------------------------------------------
diff --git a/modules/platforms/dotnet/Apache.Ignite.Core.Tests/MessagingTest.cs b/modules/platforms/dotnet/Apache.Ignite.Core.Tests/MessagingTest.cs
index 8b57c81..a35aeff 100644
--- a/modules/platforms/dotnet/Apache.Ignite.Core.Tests/MessagingTest.cs
+++ b/modules/platforms/dotnet/Apache.Ignite.Core.Tests/MessagingTest.cs
@@ -256,7 +256,7 @@ namespace Apache.Ignite.Core.Tests
 
             messaging.Send(NextMessage());
 
-            Thread.Sleep(MessagingTestHelper.MessageTimeout);
+            Thread.Sleep(MessagingTestHelper.SleepTimeout);
 
             // Check that unsubscription worked properly
             Assert.AreEqual(sharedResult, Thread.VolatileRead(ref sharedReceived));
@@ -392,7 +392,7 @@ namespace Apache.Ignite.Core.Tests
 
             messaging.Send(NextMessage()); // send a message to make filters return false
 
-            Thread.Sleep(MessagingTestHelper.MessageTimeout); // wait for all to unsubscribe
+            Thread.Sleep(MessagingTestHelper.SleepTimeout); // wait for all to unsubscribe
 
             MessagingTestHelper.ListenResult = true;
 
@@ -403,7 +403,7 @@ namespace Apache.Ignite.Core.Tests
             var lastMsg = NextMessage();
             messaging.Send(lastMsg);
 
-            Thread.Sleep(MessagingTestHelper.MessageTimeout);
+            Thread.Sleep(MessagingTestHelper.SleepTimeout);
 
             // Check that unsubscription worked properly
             var sharedResult = MessagingTestHelper.ReceivedMessages.ToArray();
@@ -476,7 +476,7 @@ namespace Apache.Ignite.Core.Tests
 
             (grid ?? _grid1).GetMessaging().SendAll(NextMessage(), topic);
 
-            Thread.Sleep(MessagingTestHelper.MessageTimeout);
+            Thread.Sleep(MessagingTestHelper.SleepTimeout);
 
             MessagingTestHelper.AssertFailures();
         }
@@ -534,7 +534,10 @@ namespace Apache.Ignite.Core.Tests
         public static volatile bool ListenResult = true;
 
         /** */
-        public static readonly TimeSpan MessageTimeout = TimeSpan.FromMilliseconds(700);
+        public static readonly TimeSpan MessageTimeout = TimeSpan.FromMilliseconds(5000);
+
+        /** */
+        public static readonly TimeSpan SleepTimeout = TimeSpan.FromMilliseconds(50);
 
         /// <summary>
         /// Clears received message information.


Mime
View raw message