std::cout demonstration of all tests in a suite being called, with setup() and teardown().
std::cout demonstration of all tests in a suite being called, with setup() and teardown().
#include <iostream>
int
main(
int argc,
char**argv
)
{
}
void setup()
{
std::cout << "\t\t\tSimpleTest: setup()";
}
void teardown()
{
std::cout << " teardown()" << std::endl;
}
{
std::cout << " a()";
}
{
std::cout << " b()";
}
{
std::cout << " c()";
}
#define TEST_SUITE_END()
Finish definition of a Test Suite started with TEST_SUITE().
#define TEST_CASE(testCaseName)
Defines a Test Case method named testCaseName within a Test Suite defined by TEST_SUITE().
#define TEST_SUITE(testSuiteName)
Defines a Test Suite named testSuiteName.
Count of tests run, and fails.
int fails
Number of tests that have failed.
Stream-based Logger for events while running tests.
Count run(Logger &logger) const
Run all tests that have been add()ed.
static TestRunner & get()
Get the singleton.