xUnit.net
Public Member Functions | Properties | List of all members
Xunit.Sdk.IXunitTestCase Interface Reference

Represents a single test case from xUnit.net v2. More...

Inheritance diagram for Xunit.Sdk.IXunitTestCase:

Public Member Functions

Task< RunSummaryRunAsync (IMessageSink diagnosticMessageSink, IMessageBus messageBus, object[] constructorArguments, ExceptionAggregator aggregator, CancellationTokenSource cancellationTokenSource)
 Executes the test case, returning 0 or more result messages through the message sink. More...
 

Properties

Exception InitializationException [get]
 Gets the exception that happened during initialization. When this is set, then the test execution should fail with this exception. More...
 
IMethodInfo Method [get]
 Gets the method to be run. Differs from ITestCase.ITestMethod.Method in that any generic argument types will have been closed based on the arguments. More...
 
int Timeout [get]
 Gets the timeout of the test, in milliseconds; if zero or negative, means the test case has no timeout. More...
 

Detailed Description

Represents a single test case from xUnit.net v2.

Member Function Documentation

◆ RunAsync()

Task<RunSummary> Xunit.Sdk.IXunitTestCase.RunAsync ( IMessageSink  diagnosticMessageSink,
IMessageBus  messageBus,
object []  constructorArguments,
ExceptionAggregator  aggregator,
CancellationTokenSource  cancellationTokenSource 
)

Executes the test case, returning 0 or more result messages through the message sink.

Parameters
diagnosticMessageSinkThe message sink used to send diagnostic messages to.
messageBusThe message bus to report results to.
constructorArgumentsThe arguments to pass to the constructor.
aggregatorThe error aggregator to use for catching exception.
cancellationTokenSourceThe cancellation token source that indicates whether cancellation has been requested.
Returns
Returns the summary of the test case run.

Property Documentation

◆ InitializationException

Exception Xunit.Sdk.IXunitTestCase.InitializationException
get

Gets the exception that happened during initialization. When this is set, then the test execution should fail with this exception.

◆ Method

IMethodInfo Xunit.Sdk.IXunitTestCase.Method
get

Gets the method to be run. Differs from ITestCase.ITestMethod.Method in that any generic argument types will have been closed based on the arguments.

◆ Timeout

int Xunit.Sdk.IXunitTestCase.Timeout
get

Gets the timeout of the test, in milliseconds; if zero or negative, means the test case has no timeout.


The documentation for this interface was generated from the following file: