Take the test's cancellation token from TUnit's TestContext
ProprietaryReplace xUnit v3's TestContext.Current.CancellationToken with TUnit's TestContext.Current!.Execution.CancellationToken.
OpenRewrite. Recipes. CSharp. Migration. TUnit. FromXUnit. TestContextCancellationTokenmod run . --recipe= OpenRewrite. Recipes. CSharp. Migration. TUnit. FromXUnit. TestContextCancellationTokenInstall it once, then run it on every repository under the current directory. New to the Moderne CLI? Set it up.