|
dot-xx
A personal collection of small C++ modules
|
Main interface file for dxx::selftest module. More...
import dxx.selftest:name_deduce;import dxx.cstd.fixed;import dxx.cstd.compat;import dxx.assert;import std;Classes | |
| class | dxx::selftest::UnitTest< TFunc > |
| Create an object of that class to declare a unit test. More... | |
| struct | dxx::selftest::test_failure |
| The exception type used by test assertions. More... | |
Namespaces | |
| namespace | dxx::selftest |
| Main namespace of dxx::selftest module. | |
Typedefs | |
| using | dxx::selftest::TestBody = std::function<void()> |
| using | dxx::selftest::TestsMap = std::map<std::string, TestBody> |
Functions | |
| void | dxx::selftest::test (bool condition, std::source_location st=std::source_location::current()) |
| Test assertion. Calls dxx::assert::always with test_failure. | |
| int | dxx::selftest::run_all (const std::unordered_set< std::string > &filters={}) |
| Run all tests that match a filter. | |
Variables | |
| constinit std::unique_ptr< TestsMap > | dxx::selftest::all_tests = nullptr |
| Storage for all unit tests. | |
Main interface file for dxx::selftest module.