Commit daf2296f authored by Nick Craver's avatar Nick Craver

Tests: remove unused EmulateStaleConnection

parent 0651c222
...@@ -110,34 +110,6 @@ public async Task FastNoticesFailOnConnectingAsyncComlpetion() ...@@ -110,34 +110,6 @@ public async Task FastNoticesFailOnConnectingAsyncComlpetion()
ClearAmbientFailures(); ClearAmbientFailures();
} }
} }
[Fact]
public async Task ReconnectsOnStaleConnection()
{
try
{
using (var muxer = Create(keepAlive: 1, connectTimeout: 3000))
{
var conn = muxer.GetDatabase();
conn.Ping();
Assert.True(muxer.IsConnected);
PhysicalConnection.EmulateStaleConnection = true;
await Task.Delay(500).ForAwait();
Assert.False(muxer.IsConnected);
PhysicalConnection.EmulateStaleConnection = false;
await Task.Delay(1000).ForAwait();
Assert.True(muxer.IsConnected);
}
}
finally
{
PhysicalConnection.EmulateStaleConnection = false;
ClearAmbientFailures();
}
}
#endif #endif
} }
} }
...@@ -85,13 +85,6 @@ internal partial class PhysicalConnection ...@@ -85,13 +85,6 @@ internal partial class PhysicalConnection
} }
public bool IgnoreConnect => BridgeCouldBeNull?.Multiplexer?.IgnoreConnect ?? false; public bool IgnoreConnect => BridgeCouldBeNull?.Multiplexer?.IgnoreConnect ?? false;
private static volatile bool emulateStaleConnection;
public static bool EmulateStaleConnection
{
get => emulateStaleConnection;
set => emulateStaleConnection = value;
}
} }
#endif #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