Table of Contents

Class BeforeAfterTestAttribute

Namespace
Xunit.v3
Assembly
xunit.v3.core.dll

Default implementation of IBeforeAfterTestAttribute.

[AttributeUsage(AttributeTargets.Assembly|AttributeTargets.Class|AttributeTargets.Method, AllowMultiple = true, Inherited = true)]
public abstract class BeforeAfterTestAttribute : Attribute, IBeforeAfterTestAttribute
Inheritance
BeforeAfterTestAttribute
Implements
Derived
Inherited Members

Methods

After(MethodInfo, IXunitTest)

This method is called after the test method is executed.

public virtual void After(MethodInfo methodUnderTest, IXunitTest test)

Parameters

methodUnderTest MethodInfo

The method under test

test IXunitTest

The current ITest

Before(MethodInfo, IXunitTest)

This method is called before the test method is executed.

public virtual void Before(MethodInfo methodUnderTest, IXunitTest test)

Parameters

methodUnderTest MethodInfo

The method under test

test IXunitTest

The current ITest