diff --git a/tests/Tgstation.Server.Tests/Live/DummyChatProvider.cs b/tests/Tgstation.Server.Tests/Live/DummyChatProvider.cs index debbf913b8..872e59e6e6 100644 --- a/tests/Tgstation.Server.Tests/Live/DummyChatProvider.cs +++ b/tests/Tgstation.Server.Tests/Live/DummyChatProvider.cs @@ -55,10 +55,10 @@ namespace Tgstation.Server.Tests.Live return mock.Object; } - public static Task RandomDisconnections(bool enabled, CancellationToken cancellationToken) + public static void RandomDisconnections(bool enabled) { // we just don't do random disconnections when live testing these days, too many potential issue vectors like thread exhaustion on actions runners - return Task.CompletedTask; + enableRandomDisconnections = enabled ? 1 : 0; } public DummyChatProvider( diff --git a/tests/Tgstation.Server.Tests/Live/Instance/WatchdogTest.cs b/tests/Tgstation.Server.Tests/Live/Instance/WatchdogTest.cs index 24e1dca471..678ef10fc7 100644 --- a/tests/Tgstation.Server.Tests/Live/Instance/WatchdogTest.cs +++ b/tests/Tgstation.Server.Tests/Live/Instance/WatchdogTest.cs @@ -158,7 +158,7 @@ namespace Tgstation.Server.Tests.Live.Instance await TestDMApiFreeDeploy(cancellationToken); // long running test likes consistency with the channels - await DummyChatProvider.RandomDisconnections(false, cancellationToken); + DummyChatProvider.RandomDisconnections(false); await RunLongRunningTestThenUpdate(cancellationToken); diff --git a/tests/Tgstation.Server.Tests/Live/TestLiveServer.cs b/tests/Tgstation.Server.Tests/Live/TestLiveServer.cs index 96ee8ba640..9ac95ce865 100644 --- a/tests/Tgstation.Server.Tests/Live/TestLiveServer.cs +++ b/tests/Tgstation.Server.Tests/Live/TestLiveServer.cs @@ -194,7 +194,7 @@ namespace Tgstation.Server.Tests.Live await CachingFileDownloader.InitializeAndInjectForLiveTests(default); - await DummyChatProvider.RandomDisconnections(true, default); + DummyChatProvider.RandomDisconnections(true); ServerClientFactory.ApiClientFactory = new RateLimitRetryingApiClientFactory(); var connectionString = Environment.GetEnvironmentVariable("TGS_TEST_CONNECTION_STRING"); @@ -1744,7 +1744,7 @@ namespace Tgstation.Server.Tests.Live await chatTestObj.RunPostTest(cancellationToken); await repoTest; - await DummyChatProvider.RandomDisconnections(false, cancellationToken); + DummyChatProvider.RandomDisconnections(false); jobsHubTest.CompleteNow(); await jobsHubTestTask;