Browse Source

Try to fix flaky test

Reda Bouallou 6 years ago
parent
commit
d557692321
1 changed files with 2 additions and 5 deletions
  1. 2 5
      src/Abc.Zebus.Tests/Transport/ZmqTransportTests.cs

+ 2 - 5
src/Abc.Zebus.Tests/Transport/ZmqTransportTests.cs

@@ -589,17 +589,14 @@ namespace Abc.Zebus.Tests.Transport
             
             transport2.Stop();
 
-            using (SystemDateTime.Set(utcNow: SystemDateTime.UtcNow.Add(30.Seconds())))
-            {
-                Wait.Until(() => transport1.OutboundSocketCount == 0, 10.Seconds());
-            }
+            Wait.Until(() => transport1.OutboundSocketCount == 0, 10.Seconds());
         }
 
         private ZmqTransport CreateAndStartZmqTransport(string endPoint = null, Action<TransportMessage> onMessageReceived = null, string peerId = null, string environment = _environment)
         {
             var configurationMock = new Mock<IZmqTransportConfiguration>();
             configurationMock.SetupGet(x => x.InboundEndPoint).Returns(endPoint);
-            configurationMock.SetupGet(x => x.WaitForEndOfStreamAckTimeout).Returns(100.Milliseconds());
+            configurationMock.SetupGet(x => x.WaitForEndOfStreamAckTimeout).Returns(1.Second());
 
             if (peerId == null)
                 peerId = $"Abc.Testing.{Guid.NewGuid():N}";