C# Class NUnit.Framework.Internal.Execution.CommandBuilder

A utility class to create TestCommands
Datei anzeigen Open project: nunit/nunit Class Usage Examples

Public Methods

Method Description
BuildSetUpTearDownList ( Type fixtureType, Type setUpType, Type tearDownType ) : List

Builds the set up tear down list.

MakeOneTimeSetUpCommand ( TestSuite suite, List setUpTearDown, List actions ) : TestCommand

Gets the command to be executed before any of the child tests are run.

MakeOneTimeTearDownCommand ( TestSuite suite, List setUpTearDownItems, List actions ) : TestCommand

Gets the command to be executed after all of the child tests are run.

MakeSkipCommand ( System.Test test ) : SkipCommand

Creates a command for skipping a test. The result returned will depend on the test RunState.

MakeTestCommand ( TestMethod test ) : TestCommand

Creates a test command for use in running this test.

Private Methods

Method Description
BuildNode ( Type fixtureType, IList setUpMethods, IList tearDownMethods ) : SetUpTearDownItem
SelectMethodsByDeclaringType ( Type type, IList methods ) : List

Method Details

BuildSetUpTearDownList() public static method

Builds the set up tear down list.
public static BuildSetUpTearDownList ( Type fixtureType, Type setUpType, Type tearDownType ) : List
fixtureType System.Type Type of the fixture.
setUpType System.Type Type of the set up attribute.
tearDownType System.Type Type of the tear down attribute.
return List

MakeOneTimeSetUpCommand() public static method

Gets the command to be executed before any of the child tests are run.
public static MakeOneTimeSetUpCommand ( TestSuite suite, List setUpTearDown, List actions ) : TestCommand
suite TestSuite
setUpTearDown List
actions List
return TestCommand

MakeOneTimeTearDownCommand() public static method

Gets the command to be executed after all of the child tests are run.
public static MakeOneTimeTearDownCommand ( TestSuite suite, List setUpTearDownItems, List actions ) : TestCommand
suite TestSuite
setUpTearDownItems List
actions List
return TestCommand

MakeSkipCommand() public static method

Creates a command for skipping a test. The result returned will depend on the test RunState.
public static MakeSkipCommand ( System.Test test ) : SkipCommand
test System.Test
return SkipCommand

MakeTestCommand() public static method

Creates a test command for use in running this test.
public static MakeTestCommand ( TestMethod test ) : TestCommand
test TestMethod
return TestCommand