diff --git a/.config/dotnet-tools.json b/.config/dotnet-tools.json index e170f47f..bc24e52d 100644 --- a/.config/dotnet-tools.json +++ b/.config/dotnet-tools.json @@ -3,7 +3,7 @@ "isRoot": true, "tools": { "csharpier": { - "version": "1.0.1", + "version": "1.0.2", "commands": [ "csharpier" ], diff --git a/tests/Speckle.Sdk.Serialization.Tests/AdditionalCancellationTests.cs b/tests/Speckle.Sdk.Serialization.Tests/AdditionalCancellationTests.cs index 90664ad2..42b01e83 100644 --- a/tests/Speckle.Sdk.Serialization.Tests/AdditionalCancellationTests.cs +++ b/tests/Speckle.Sdk.Serialization.Tests/AdditionalCancellationTests.cs @@ -36,7 +36,7 @@ public class AdditionalCancellationTests ); var task = serializeProcess.Serialize(testClass); - cancellationSource.Cancel(); + await cancellationSource.CancelAsync(); var ex = await Assert.ThrowsAsync(async () => await task); await Verify(ex); @@ -64,7 +64,7 @@ public class AdditionalCancellationTests tasks.Add(serializeProcess.Serialize(i % 2 == 0 ? testClass1 : testClass2)); } - cancellationSource.Cancel(); + await cancellationSource.CancelAsync(); while (tasks.Count != 0) { @@ -94,7 +94,7 @@ public class AdditionalCancellationTests ); await serializeProcess.Serialize(testClass); - cancellationSource.Cancel(); // Cancel after completion + await cancellationSource.CancelAsync(); cancellationSource.IsCancellationRequested.Should().BeTrue(); } diff --git a/tests/Speckle.Sdk.Tests.Integration/Api/GraphQL/Resources/ProjectResourceExceptionalTests.cs b/tests/Speckle.Sdk.Tests.Integration/Api/GraphQL/Resources/ProjectResourceExceptionalTests.cs index 13803e5a..7da9f67e 100644 --- a/tests/Speckle.Sdk.Tests.Integration/Api/GraphQL/Resources/ProjectResourceExceptionalTests.cs +++ b/tests/Speckle.Sdk.Tests.Integration/Api/GraphQL/Resources/ProjectResourceExceptionalTests.cs @@ -118,7 +118,8 @@ public class ProjectResourceExceptionalTests : IAsyncLifetime { ProjectUpdateRoleInput input = new(_secondUser.Account.id.NotNull(), "NonExistentProject", newRole); - var ex = await Assert.ThrowsAsync(async () => _ = await _unauthedUser.Project.UpdateRole(input) + var ex = await Assert.ThrowsAsync(async () => + _ = await _unauthedUser.Project.UpdateRole(input) ); ex.InnerExceptions.Single().Should().BeOfType(); } diff --git a/tests/Speckle.Sdk.Tests.Unit/Helpers/SpeckleHttpTests.cs b/tests/Speckle.Sdk.Tests.Unit/Helpers/SpeckleHttpTests.cs index 22040c4d..0ac837ce 100644 --- a/tests/Speckle.Sdk.Tests.Unit/Helpers/SpeckleHttpTests.cs +++ b/tests/Speckle.Sdk.Tests.Unit/Helpers/SpeckleHttpTests.cs @@ -36,7 +36,8 @@ public class SpeckleHttpTests : MoqTest var uri = new Uri("https://speckle.xyz"); mockHttp.When(uri.AbsoluteUri).Respond(HttpStatusCode.Unauthorized); - await Assert.ThrowsAsync(async () => await speckleHttp.HttpPing(uri, mockHttp.ToHttpClient()) + await Assert.ThrowsAsync(async () => + await speckleHttp.HttpPing(uri, mockHttp.ToHttpClient()) ); }