Class ProtoTestAttribute
Custom MSTest method attribute that manages the ProtoTest execution context lifecycle asynchronously. MSTest invokes this once per data row, so each row is its own lifecycle and its own trace.
[AttributeUsage(AttributeTargets.Method, AllowMultiple = false)]
public class ProtoTestAttribute : TestMethodAttribute
- Inheritance
-
TestMethodAttributeProtoTestAttribute
- Inherited Members
-
TestMethodAttribute.DisplayNameTestMethodAttribute.UnfoldingStrategyTestMethodAttribute.DeclaringFilePathTestMethodAttribute.DeclaringLineNumber
- Extension Methods
Constructors
ProtoTestAttribute(string, int)
Custom MSTest method attribute that manages the ProtoTest execution context lifecycle asynchronously. MSTest invokes this once per data row, so each row is its own lifecycle and its own trace.
public ProtoTestAttribute(string callerFilePath = "", int callerLineNumber = -1)
Parameters
Methods
ExecuteAsync(ITestMethod)
Executes a test method.
public override Task<TestResult[]> ExecuteAsync(ITestMethod testMethod)
Parameters
testMethodITestMethodThe test method to execute.
Returns
- Task<TestResult[]>
An array of TestResult objects that represent the outcome(s) of the test.
Remarks
Extensions can override this method to customize running a TestMethod.