Commit 80731aa0 authored by Pavel Pochobut's avatar Pavel Pochobut

correct tear down for ConnectingFailDetection

parent d994b7ad
......@@ -8,7 +8,7 @@ namespace StackExchange.Redis.Tests
public class ConnectingFailDetection : TestBase
{
#if DEBUG
[TestCase]
[Test]
public void FastNoticesFailOnConnectingSync()
{
try
......@@ -34,16 +34,15 @@ public void FastNoticesFailOnConnectingSync()
Assert.IsTrue(muxer.IsConnected);
}
ClearAmbientFailures();
}
finally
{
SocketManager.ConnectCompletionType = CompletionType.Any;
ClearAmbientFailures();
}
}
[TestCase]
[Test]
public void ConnectsWhenBeginConnectCompletesSynchronously()
{
try
......@@ -57,16 +56,15 @@ public void ConnectsWhenBeginConnectCompletesSynchronously()
Assert.IsTrue(muxer.IsConnected);
}
ClearAmbientFailures();
}
finally
{
SocketManager.ConnectCompletionType = CompletionType.Any;
ClearAmbientFailures();
}
}
[TestCase]
[Test]
public void FastNoticesFailOnConnectingAsync()
{
try
......@@ -92,13 +90,12 @@ public void FastNoticesFailOnConnectingAsync()
Thread.Sleep(2000);
Assert.IsTrue(muxer.IsConnected);
ClearAmbientFailures();
}
}
finally
{
SocketManager.ConnectCompletionType = CompletionType.Any;
ClearAmbientFailures();
}
}
#endif
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment