TestCase is a class that holds the test case information. There are several fields that are used to store the test case information.
More...
#include <unittest.h>
TestCase is a class that holds the test case information. There are several fields that are used to store the test case information.
- name : The name of the test case.
- file : The file that the test case is defined.
- line : The line that the test case is defined.
- func : The function that will be run to test the test case.
- subcases : The subcases that are defined in the test case.
◆ TestCase() [1/2]
zeroerr::TestCase::TestCase |
( |
std::string |
name, |
|
|
std::string |
file, |
|
|
unsigned |
line |
|
) |
| |
|
inline |
Construct a new Test Case object.
- Parameters
-
name | The name of the test case. |
file | The file that the test case is defined. |
line | The line that the test case is defined. |
◆ TestCase() [2/2]
zeroerr::TestCase::TestCase |
( |
std::string |
name, |
|
|
std::string |
file, |
|
|
unsigned |
line, |
|
|
std::function< void(TestContext *)> |
func |
|
) |
| |
|
inline |
Construct a new Test Case object.
- Parameters
-
name | The name of the test case. |
file | The file that the test case is defined. |
line | The line that the test case is defined. |
func | The function that will be run to test the test case. |
◆ operator<()
bool zeroerr::TestCase::operator< |
( |
const TestCase & |
rhs | ) |
const |
Compare the test cases.
- Parameters
-
rhs | The test case that will be compared. |
- Returns
- true If the test case is less than the rhs, otherwise false.
◆ file
std::string zeroerr::TestCase::file |
◆ func
std::function<void(TestContext*)> zeroerr::TestCase::func |
◆ line
unsigned zeroerr::TestCase::line |
◆ name
std::string zeroerr::TestCase::name |
◆ subcases
std::vector<TestCase*> zeroerr::TestCase::subcases |
The documentation for this struct was generated from the following files: