Method OnTestStarting
- Namespace
- Xunit.v3
- Assembly
- xunit.v3.core.dll
OnTestStarting(TContext)
This method is called just before the test is run. By default, this sends TestStarting. Override this to enable any extensibility related to test start.
protected override ValueTask<bool> OnTestStarting(TContext ctxt)
Parameters
ctxtTContextThe context that describes the current test
Returns
Remarks
This method runs during Initializing and any exceptions thrown will contribute to test failure (and will prevent the test from running). Even if this method records exceptions, OnTestFinished(TContext, decimal, string, string[]?) will be called.