|
qxLib
|
Selects assertion properties and the number of expected occurrences. More...
#include <expected_assert.h>
Public Member Functions | |
| expected_assert_builder & | condition (string_view svCondition, bool bRegex=false) |
| Match the failed condition text. More... | |
| expected_assert_builder & | category (const qx::category &category) |
| Require the specified assertion category. More... | |
| expected_assert_builder & | type (assert_type eType) |
| Require the specified assertion type. More... | |
| expected_assert_builder & | message (string_view svPattern, bool bRegex=false) |
| Match the formatted user message. More... | |
| expected_assert_builder & | function (string_view svFunction, bool bRegex=false) |
| Match the function name. More... | |
| expected_assert_builder & | file (string_view svFile, bool bRegex=false) |
| Match the source file name. More... | |
| expected_assert_builder & | line (i32 nLine) |
| Require the exact source line number. More... | |
| expected_assert_builder & | count (size_t nCount) |
| Require exactly this many matching assertions. More... | |
| expected_assert | build () const |
| Start observing assertions using the selected criteria. More... | |
Selects assertion properties and the number of expected occurrences.
Only specified properties are matched. Strings match exactly unless regex search is enabled; a selected category must outlive the expectation. The default expected count is one.
Definition at line 37 of file expected_assert.h.
|
inline |
Start observing assertions using the selected criteria.
Definition at line 82 of file expected_assert.inl.
|
inline |
Require the specified assertion category.
| category | - expected value |
Definition at line 40 of file expected_assert.inl.
|
inline |
Match the failed condition text.
| svCondition | - expected text or regex pattern |
| bRegex | - search using a regex instead of comparing the complete text |
Definition at line 34 of file expected_assert.inl.
|
inline |
Require exactly this many matching assertions.
| nCount | - expected value |
Definition at line 76 of file expected_assert.inl.
|
inline |
Match the source file name.
| svFile | - expected text or regex pattern |
| bRegex | - search using a regex instead of comparing the complete text |
Definition at line 64 of file expected_assert.inl.
|
inline |
Match the function name.
| svFunction | - expected text or regex pattern |
| bRegex | - search using a regex instead of comparing the complete text |
Definition at line 58 of file expected_assert.inl.
|
inline |
Require the exact source line number.
| nLine | - expected value |
Definition at line 70 of file expected_assert.inl.
|
inline |
Match the formatted user message.
| svPattern | - expected text or regex pattern |
| bRegex | - search using a regex instead of comparing the complete text |
Definition at line 52 of file expected_assert.inl.
|
inline |
Require the specified assertion type.
| eType | - expected value |
Definition at line 46 of file expected_assert.inl.