Base class for all test suites.
More...
#include <micro-os-plus/micro-test-plus.h>
Base class for all test suites.
Definition at line 50 of file test-suite.h.
◆ test_suite_base() [1/3]
micro_os_plus::micro_test_plus::test_suite_base::test_suite_base |
( |
const char * | name | ) |
|
Construct a test suite.
- Parameters
-
[in] | name | The test suite name. |
Definition at line 38 of file test-suite.cpp.
◆ test_suite_base() [2/3]
micro_os_plus::micro_test_plus::test_suite_base::test_suite_base |
( |
const test_suite_base & | | ) |
|
|
delete |
◆ test_suite_base() [3/3]
micro_os_plus::micro_test_plus::test_suite_base::test_suite_base |
( |
test_suite_base && | | ) |
|
|
delete |
◆ ~test_suite_base()
micro_os_plus::micro_test_plus::test_suite_base::~test_suite_base |
( |
| ) |
|
|
virtual |
◆ begin_test_case()
void micro_os_plus::micro_test_plus::test_suite_base::begin_test_case |
( |
const char * | name | ) |
|
Mark the beginning of a named test case.
- Parameters
-
[in] | name | The test case name. |
- Returns
- Nothing.
Definition at line 79 of file test-suite.cpp.
◆ begin_test_suite()
void micro_os_plus::micro_test_plus::test_suite_base::begin_test_suite |
( |
void | | ) |
|
Begin the execution of the test suite.
- Parameters
- None.
- Returns
- Nothing.
Definition at line 61 of file test-suite.cpp.
◆ end_test_case()
void micro_os_plus::micro_test_plus::test_suite_base::end_test_case |
( |
void | | ) |
|
Mark the end of a test case.
- Parameters
- None.
- Returns
- Nothing.
Definition at line 95 of file test-suite.cpp.
◆ end_test_suite()
void micro_os_plus::micro_test_plus::test_suite_base::end_test_suite |
( |
void | | ) |
|
Mark the end of the test suite.
- Parameters
- None.
- Returns
- Nothing.
Definition at line 69 of file test-suite.cpp.
◆ failed_checks()
constexpr int micro_os_plus::micro_test_plus::test_suite_base::failed_checks |
( |
void | | ) |
|
|
inlineconstexpr |
Get the number of conditions that failed.
- Parameters
- None.
- Returns
- An integer with the number checks that failed.
Definition at line 151 of file test-suite.h.
◆ increment_failed()
void micro_os_plus::micro_test_plus::test_suite_base::increment_failed |
( |
void | | ) |
|
Count one more failed test conditions.
- Parameters
- None.
- Returns
- Nothing.
Definition at line 108 of file test-suite.cpp.
◆ increment_successful()
void micro_os_plus::micro_test_plus::test_suite_base::increment_successful |
( |
void | | ) |
|
Count one more passed test conditions.
- Parameters
- None.
- Returns
- Nothing.
Definition at line 101 of file test-suite.cpp.
◆ name()
constexpr const char * micro_os_plus::micro_test_plus::test_suite_base::name |
( |
| ) |
|
|
inlineconstexpr |
Get the suite name.
- Parameters
- None.
- Returns
- A pointer to the null terminated test suite name.
Definition at line 107 of file test-suite.h.
◆ operator=() [1/2]
◆ operator=() [2/2]
◆ run()
void micro_os_plus::micro_test_plus::test_suite_base::run |
( |
void | | ) |
|
|
virtual |
◆ successful_checks()
constexpr int micro_os_plus::micro_test_plus::test_suite_base::successful_checks |
( |
void | | ) |
|
|
inlineconstexpr |
Get the number of conditions that passed.
- Parameters
- None.
- Returns
- An integer with the number checks that passed.
Definition at line 139 of file test-suite.h.
◆ test_cases()
constexpr int micro_os_plus::micro_test_plus::test_suite_base::test_cases |
( |
void | | ) |
|
|
inlineconstexpr |
Get the number of test cases.
- Parameters
- None.
- Returns
- An integer with the number of test cases.
Definition at line 163 of file test-suite.h.
◆ unused()
constexpr bool micro_os_plus::micro_test_plus::test_suite_base::unused |
( |
void | | ) |
|
|
inlineconstexpr |
If all counter are null, it is unused.
- Parameters
- None.
- Returns
- True if the test suite is not used.
Definition at line 208 of file test-suite.h.
◆ was_successful()
constexpr bool micro_os_plus::micro_test_plus::test_suite_base::was_successful |
( |
void | | ) |
|
|
inlineconstexpr |
Get the test suite result.
- Parameters
- None.
- Returns
- True if the test suite was successful.
Definition at line 195 of file test-suite.h.
◆ [struct]
struct { ... } micro_os_plus::micro_test_plus::test_suite_base::current_test_case |
◆ failed_checks
int micro_os_plus::micro_test_plus::test_suite_base::failed_checks |
◆ failed_checks_
int micro_os_plus::micro_test_plus::test_suite_base::failed_checks_ = 0 |
|
protected |
Count of test conditions that failed.
Definition at line 233 of file test-suite.h.
◆ name_
const char* micro_os_plus::micro_test_plus::test_suite_base::name_ |
|
protected |
◆ process_deferred_begin
bool micro_os_plus::micro_test_plus::test_suite_base::process_deferred_begin = true |
◆ successful_checks
int micro_os_plus::micro_test_plus::test_suite_base::successful_checks |
◆ successful_checks_
int micro_os_plus::micro_test_plus::test_suite_base::successful_checks_ = 0 |
|
protected |
Count of test conditions that passed.
Definition at line 228 of file test-suite.h.
◆ test_case_name_
const char* micro_os_plus::micro_test_plus::test_suite_base::test_case_name_ |
|
protected |
◆ test_cases_
int micro_os_plus::micro_test_plus::test_suite_base::test_cases_ = 0 |
|
protected |
Count of test cases in the test suite.
Definition at line 238 of file test-suite.h.
The documentation for this class was generated from the following files: