Welcome to the new CppUtils documentation!
CppUtils::UnitTest::TestSuite
STRUCTCore test suite execution context providing assertion methods, builders, and test registration.
Description
Section titled “Description”Instances are passed to test suite definitions configured via testSuite("SuiteName") = [](TestSuite& suite) { ... };. Supports regular tests, compile-time tests, parameterized tests (types, values, ranges), fuzz tests, and benchmarks.
Public types
Section titled “Public types”Logger
Section titled “Logger”using CppUtils::UnitTest::TestSuite::Logger = Logger<"UnitTests">;Public attributes
Section titled “Public attributes”Public methods
Section titled “Public methods”Declares a test case with the specified name, returning a builder to configure and assign its body.
| Parameter | Description |
|---|---|
name | Descriptive test name. |
Returns: TestBuilder instance.
[[nodiscard]] auto TestSuite::fuzzTest(std::string name, std::size_t iterations) -> FuzzTestBuilder<false>;Registers a fuzz test executed for a specified number of randomized iterations.
| Parameter | Description |
|---|---|
name | Test identifier. |
iterations | Number of iterations to run. |
Returns: FuzzTestBuilder for assigning the test body callback.