|
OTest2
A C++ testing framework
|
Builder of test marks. More...
#include <testmarkbuilder.h>
Classes | |
| struct | Impl |
Public Member Functions | |
| TestMarkBuilder () | |
| Ctor. More... | |
| ~TestMarkBuilder () | |
| Dtor. More... | |
| TestMarkBuilder (const TestMarkBuilder &)=delete | |
| TestMarkBuilder & | operator= (const TestMarkBuilder &)=delete |
| void | setKey (const std::string &key_) |
| Set current key. More... | |
| void | appendMark (TestMarkPtr mark_) |
| Append new test mark. More... | |
| void | appendNull () |
| Append the null mark. More... | |
| void | appendBool (bool value_) |
| Append a boolean mark. More... | |
| void | appendInt (int64_t value_) |
| Append an integer mark. More... | |
| void | appendFloat (long double value_) |
| Append a float mark. More... | |
| void | appendString (const std::string &value_) |
| Append a string mark. More... | |
| template<typename ContainerMark_ > | |
| void | openContainer (std::unique_ptr< ContainerMark_ > &&container_) |
| Open a new nested level of test mark container. More... | |
| void | openList () |
| Open new nested list. More... | |
| void | openList (const std::string &prefix_) |
| Open new nested list. More... | |
| void | openMap () |
| Open nested map. More... | |
| void | openMap (const std::string &prefix_) |
| Open nested map. More... | |
| void | closeContainer () |
| Close currently opened container. More... | |
| TestMarkPtr | stealMark () const |
| Get constructed testmark and reset the builder. More... | |
Builder of test marks.
Definition at line 37 of file testmarkbuilder.h.
| OTest2::TestMarkBuilder::TestMarkBuilder | ( | ) |
Ctor.
Definition at line 112 of file testmarkbuilder.cpp.
| OTest2::TestMarkBuilder::~TestMarkBuilder | ( | ) |
Dtor.
Definition at line 119 of file testmarkbuilder.cpp.
|
delete |
| void OTest2::TestMarkBuilder::appendBool | ( | bool | value_ | ) |
Append a boolean mark.
| value_ | The boolean value |
Definition at line 138 of file testmarkbuilder.cpp.
| void OTest2::TestMarkBuilder::appendFloat | ( | long double | value_ | ) |
Append a float mark.
| value_ | The float value |
Definition at line 148 of file testmarkbuilder.cpp.
| void OTest2::TestMarkBuilder::appendInt | ( | int64_t | value_ | ) |
Append an integer mark.
| value_ | The integer value |
Definition at line 143 of file testmarkbuilder.cpp.
| void OTest2::TestMarkBuilder::appendMark | ( | TestMarkPtr | mark_ | ) |
| void OTest2::TestMarkBuilder::appendNull | ( | ) |
Append the null mark.
Definition at line 134 of file testmarkbuilder.cpp.
| void OTest2::TestMarkBuilder::appendString | ( | const std::string & | value_ | ) |
Append a string mark.
| value_ | The string value |
Definition at line 153 of file testmarkbuilder.cpp.
| void OTest2::TestMarkBuilder::closeContainer | ( | ) |
Close currently opened container.
The method closes currently opened container, pops it from the stack and appends it to upper container.
Definition at line 181 of file testmarkbuilder.cpp.
|
inline |
Open a new nested level of test mark container.
| container_ | The nested container |
Definition at line 200 of file testmarkbuilder.h.
| void OTest2::TestMarkBuilder::openList | ( | ) |
Open new nested list.
Definition at line 163 of file testmarkbuilder.cpp.
| void OTest2::TestMarkBuilder::openList | ( | const std::string & | prefix_ | ) |
Open new nested list.
| prefix_ | Prefix of the list |
Definition at line 167 of file testmarkbuilder.cpp.
| void OTest2::TestMarkBuilder::openMap | ( | ) |
Open nested map.
Definition at line 172 of file testmarkbuilder.cpp.
| void OTest2::TestMarkBuilder::openMap | ( | const std::string & | prefix_ | ) |
Open nested map.
| prefix_ | Prefix of the map |
Definition at line 176 of file testmarkbuilder.cpp.
|
delete |
| void OTest2::TestMarkBuilder::setKey | ( | const std::string & | key_ | ) |
| TestMarkPtr OTest2::TestMarkBuilder::stealMark | ( | ) | const |
Get constructed testmark and reset the builder.
Definition at line 187 of file testmarkbuilder.cpp.
1.8.17