Commit 82e68d6c authored by Nick Craver's avatar Nick Craver

Optimize test times a bit

parent 88dcf0c9
...@@ -48,7 +48,7 @@ public async Task DeslaveGoesToPrimary() ...@@ -48,7 +48,7 @@ public async Task DeslaveGoesToPrimary()
primary.MakeMaster(ReplicationChangeOptions.SetTiebreaker); primary.MakeMaster(ReplicationChangeOptions.SetTiebreaker);
secondary.MakeMaster(ReplicationChangeOptions.None); secondary.MakeMaster(ReplicationChangeOptions.None);
await Task.Delay(2000).ConfigureAwait(false); await Task.Delay(100).ConfigureAwait(false);
primary.Ping(); primary.Ping();
secondary.Ping(); secondary.Ping();
...@@ -75,7 +75,7 @@ public async Task DeslaveGoesToPrimary() ...@@ -75,7 +75,7 @@ public async Task DeslaveGoesToPrimary()
primary.MakeMaster(ReplicationChangeOptions.Broadcast | ReplicationChangeOptions.EnslaveSubordinates | ReplicationChangeOptions.SetTiebreaker, Writer); primary.MakeMaster(ReplicationChangeOptions.Broadcast | ReplicationChangeOptions.EnslaveSubordinates | ReplicationChangeOptions.SetTiebreaker, Writer);
Writer.WriteLine("Finished MakeMaster() call."); Writer.WriteLine("Finished MakeMaster() call.");
await Task.Delay(2000).ConfigureAwait(false); await Task.Delay(100).ConfigureAwait(false);
Writer.WriteLine("Invoking Ping() (post-master)"); Writer.WriteLine("Invoking Ping() (post-master)");
primary.Ping(); primary.Ping();
......
...@@ -75,7 +75,7 @@ public async Task SubscriptionsSurviveMasterSwitchAsync(bool useSharedSocketMana ...@@ -75,7 +75,7 @@ public async Task SubscriptionsSurviveMasterSwitchAsync(bool useSharedSocketMana
subA.Ping(); subA.Ping();
subB.Ping(); subB.Ping();
Output.WriteLine("Pausing..."); Output.WriteLine("Pausing...");
await Task.Delay(4000).ForAwait(); await Task.Delay(6000).ForAwait();
Assert.True(a.GetServer(TestConfig.Current.MasterServerAndPort).IsSlave, $"{TestConfig.Current.MasterServerAndPort} should be a slave via a"); Assert.True(a.GetServer(TestConfig.Current.MasterServerAndPort).IsSlave, $"{TestConfig.Current.MasterServerAndPort} should be a slave via a");
Assert.False(a.GetServer(TestConfig.Current.SlaveServerAndPort).IsSlave, $"{TestConfig.Current.SlaveServerAndPort} should be a master via a"); Assert.False(a.GetServer(TestConfig.Current.SlaveServerAndPort).IsSlave, $"{TestConfig.Current.SlaveServerAndPort} should be a master via a");
......
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