diff --git a/Directory.Packages.props b/Directory.Packages.props index ebd5af2..af7318f 100644 --- a/Directory.Packages.props +++ b/Directory.Packages.props @@ -4,9 +4,9 @@ - - - + + + diff --git a/KtsuBuild.Tests/Utilities/ProcessRunnerTests.cs b/KtsuBuild.Tests/Utilities/ProcessRunnerTests.cs index 2733552..7d36e8e 100644 --- a/KtsuBuild.Tests/Utilities/ProcessRunnerTests.cs +++ b/KtsuBuild.Tests/Utilities/ProcessRunnerTests.cs @@ -238,7 +238,9 @@ public async Task RunWithCallbackAsync_WhenCancelled_KillsTheChildInsteadOfAband await Task.Delay(TimeSpan.FromSeconds(1)).ConfigureAwait(false); await cts.CancelAsync().ConfigureAwait(false); - await Assert.ThrowsExactlyAsync(() => running).ConfigureAwait(false); + // ktsu.RunCommand reports cancellation from ThrowIfCancellationRequested, which throws the base + // OperationCanceledException rather than TaskCanceledException, so accept any cancellation. + await Assert.ThrowsAsync(() => running).ConfigureAwait(false); // Well past the point the child would have written the marker had it been left alone. await Task.Delay(TimeSpan.FromSeconds(6)).ConfigureAwait(false);