Welcome to the new CppUtils documentation!
CppUtils::UnitTest::TestSuite::TestBuilderBase<class Derived, bool IsSkipped>
STRUCTBase CRTP helper providing common configuration (timeout, skip) for test builders.
Description
Section titled “Description”| Template parameter | Description |
|---|---|
Derived | Derived builder type for method chaining. |
IsSkipped | Indicates whether the test execution is bypassed. |
Public attributes
Section titled “Public attributes”Public methods
Section titled “Public methods”Sets the execution timeout before the test is aborted.
| Parameter | Description |
|---|---|
newTimeout | Timeout duration. |
Returns: Reference to this builder.
Deliberately marks this test case to be skipped.
| Parameter | Description |
|---|---|
message | Justification for skipping. |
Returns: Rebound builder with skipping enabled.
Conditionally marks this test case to be skipped.
| Template parameter | Description |
|---|---|
Condition | Compile-time condition flag. |
| Parameter | Description |
|---|---|
message | Justification for skipping. |
Returns: Rebound builder configured with the specified condition.
template <class Function>auto TestBuilderBase::addTest(std::string name, Function&& function, std::chrono::seconds timeout) -> void;Adds a test callback into the parent suite, taking skip status into account.
| Parameter | Description |
|---|---|
name | Test identifier. |
function | Invocable test body. |
timeout | Execution timeout duration. |