Class HegelTestCase
The xUnit test case of a HegelTestAttribute method: one test, whose body the engine runs. Created by HegelTestDiscoverer; not used directly.
public sealed class HegelTestCase : XunitTestCase, IDisposable, IXunitTestCase, ITestCase, IXunitSerializable
- Inheritance
-
LongLivedMarshalByRefObjectTestMethodTestCaseXunitTestCaseHegelTestCase
- Implements
-
IXunitTestCaseITestCaseIXunitSerializable
- Inherited Members
-
XunitTestCase.Serialize(IXunitSerializationInfo)XunitTestCase.Deserialize(IXunitSerializationInfo)XunitTestCase.TimeoutTestMethodTestCase.Dispose()TestMethodTestCase.DisplayNameTestMethodTestCase.InitializationExceptionTestMethodTestCase.MethodTestMethodTestCase.SkipReasonTestMethodTestCase.SourceInformationTestMethodTestCase.TestMethodTestMethodTestCase.TestMethodArgumentsTestMethodTestCase.TraitsTestMethodTestCase.UniqueIDLongLivedMarshalByRefObject.DisconnectAll()
Constructors
HegelTestCase(IMessageSink, TestMethodDisplay, TestMethodDisplayOptions, ITestMethod)
Called by HegelTestDiscoverer.
public HegelTestCase(IMessageSink diagnosticMessageSink, TestMethodDisplay defaultMethodDisplay, TestMethodDisplayOptions defaultMethodDisplayOptions, ITestMethod testMethod)
Parameters
diagnosticMessageSinkIMessageSinkdefaultMethodDisplayTestMethodDisplaydefaultMethodDisplayOptionsTestMethodDisplayOptionstestMethodITestMethod
Methods
RunAsync(IMessageSink, IMessageBus, object[], ExceptionAggregator, CancellationTokenSource)
Executes the test case, returning 0 or more result messages through the message sink.
public override Task<RunSummary> RunAsync(IMessageSink diagnosticMessageSink, IMessageBus messageBus, object[] constructorArguments, ExceptionAggregator aggregator, CancellationTokenSource cancellationTokenSource)
Parameters
diagnosticMessageSinkIMessageSinkThe message sink used to send diagnostic messages to.
messageBusIMessageBusThe message bus to report results to.
constructorArgumentsobject[]The arguments to pass to the constructor.
aggregatorExceptionAggregatorThe error aggregator to use for catching exception.
cancellationTokenSourceCancellationTokenSourceThe cancellation token source that indicates whether cancellation has been requested.
Returns
- Task<RunSummary>
Returns the summary of the test case run.