dotnet/BenchmarkDotNet
Add CancellationToken support on non-async benchmark runner APIs
クローズ
#3,204 opened on 2026/07/22
good first issueup-for-grabs
Repository metrics
- Stars
- (11,472 個のスター)
- PR merge metrics
- (平均マージ 5d 9h) (30d で 20 merged PRs)
説明
Currently BenchmarkDotNet support CancellationToken on Async APIs.
It's also desirable to support CancellationToken on non-async APIs also on BenchmarkSwitcher/BenchmarkRunner.
Expected usage
Use xUnit.v3's TestContext.Current.CancellationToken to run benchmarks.
Without