arcus-azure/arcus.testing

✨ [New]: pass cancellation token to test fixtures

Offen

#507 geöffnet am 24.02.2026

 (0 Kommentare) (0 Reaktionen) (0 zugewiesene Personen)C# (6 Forks)auto 404
featuregood first issue

Repository-Metriken

Stars
 (9 Sterne)
PR-Merge-Metriken
 (PR-Metriken ausstehend)

Beschreibung

Description

With the new update of xUnit and the update throughout other testing frameworks as well, there is support available for test cancellation. This makes sure that tests cancelled by the user are faster finished (still keeping the teardown process in mind).

Solution

We should make sure that the following libraries have test cancellation support:

Additional context

The process of adding cancellation support is:

  1. Determine the 'setup' operations on the test fixture.
  2. Create new overloads with the CancellationToken parameter.
  3. Use the CancellationToken parameter throughout the 'setup' operations.
  4. Mark the non-cancellation overloads obsolete & replace implementation with delegation to cancellation-supported overloads.

Contributor Guide