diff --git a/test/Common/ProtocolTests.cs b/test/Common/ProtocolTests.cs index 4653bc7..26961b4 100644 --- a/test/Common/ProtocolTests.cs +++ b/test/Common/ProtocolTests.cs @@ -978,7 +978,11 @@ namespace Test.Amqp Assert.IsTrue(transport != null, "transport is null"); try { - transport.WriteByte(1); + for (int i = 0; i < 5; i++) + { + transport.WriteByte(1); + Thread.Sleep(100); + } Assert.IsTrue(false, "transport not disposed 1."); } catch (ObjectDisposedException) { } @@ -997,7 +1001,11 @@ namespace Test.Amqp Assert.IsTrue(transport != null, "transport is null 2"); try { - transport.WriteByte(2); + for (int i = 0; i < 5; i++) + { + transport.WriteByte(2); + Thread.Sleep(100); + } Assert.IsTrue(false, "transport not disposed 2."); } catch (ObjectDisposedException) { }