Class TestCase

Description:

The TestCase class is responsible for executing a specific test case. The test case to be executed is specified through the Name and TestContainer properties in the class. The Run method will call the appropriate Setup and TearDown methods for the test case as well as executing the test case method itself.

Note: this class has an instancing property of PublicNotCreatable. It can only be instantiated by classes in the test framework.

Interface Implementation:

Known Subclasses:

Method Summary:

Method:Definition:
CountTestCases Public Function CountTestCases() As Integer
Initialize Public Sub Initialize(sName As String, oTestContainer As ITestContainer)
Name Public Property Get Name() As String
Run Public Sub Run(ByRef oTestResult As TestResult)
TestContainer Public Property Get TestContainer() As ITestContainer

Methods:

Initialize

Definition:
Public Sub Initialize(sName As String, oTestContainer As ITestContainer)
Description:
Initializes the TestCase. Used in lieu of a constructor.

Name

Definition:
Public Property Get Name() As String
Description:
Name of the test case

TestContainer

Definition:
Public Property Get TestContainer() As ITestContainer
Description:
Reference to the test container containing the test method to be executed.

Run

Definition:
Public Sub Run(ByRef oTestResult As TestResult)
Description:
Runs the test and collects the results in the TestResult parameter

CountTestCases

Definition:
Public Function CountTestCases() As Integer
Description:
Number of test cases contained in this test