JUnit-compatible XML outputter. More...
#include <hayai_junit_xml_outputter.hpp>

Classes | |
| class | TestCase |
| Test case. More... | |
Public Member Functions | |
| virtual void | Begin (const std::size_t &enabledCount, const std::size_t &disabledCount) |
| Begin benchmarking. | |
| virtual void | BeginTest (const std::string &fixtureName, const std::string &testName, const TestParametersDescriptor ¶meters, const std::size_t &runsCount, const std::size_t &iterationsCount) |
| Begin benchmark test run. | |
| virtual void | End (const std::size_t &executedCount, const std::size_t &disabledCount) |
| End benchmarking. | |
| virtual void | EndTest (const std::string &fixtureName, const std::string &testName, const TestParametersDescriptor ¶meters, const TestResult &result) |
| End benchmark test run. | |
| JUnitXmlOutputter (std::ostream &stream) | |
| Initialize outputter. | |
| virtual void | SkipDisabledTest (const std::string &fixtureName, const std::string &testName, const TestParametersDescriptor ¶meters, const std::size_t &runsCount, const std::size_t &iterationsCount) |
| Skip disabled benchmark test run. | |
Private Types | |
| typedef std::map< std::string, std::vector< TestCase > > | TestSuiteMap |
| Test suite map. | |
Private Member Functions | |
| void | WriteEscapedString (const std::string &str) |
| Write an escaped string. | |
Private Attributes | |
| std::ostream & | _stream |
| TestSuiteMap | _testSuites |
JUnit-compatible XML outputter.
Definition at line 15 of file hayai_junit_xml_outputter.hpp.
typedef std::map<std::string, std::vector<TestCase> > hayai::JUnitXmlOutputter::TestSuiteMap [private] |
Test suite map.
Definition at line 57 of file hayai_junit_xml_outputter.hpp.
| hayai::JUnitXmlOutputter::JUnitXmlOutputter | ( | std::ostream & | stream | ) | [inline] |
Initialize outputter.
| stream | Output stream. Must exist for the entire duration of the outputter's use. |
Definition at line 63 of file hayai_junit_xml_outputter.hpp.
| virtual void hayai::JUnitXmlOutputter::Begin | ( | const std::size_t & | enabledCount, |
| const std::size_t & | disabledCount | ||
| ) | [inline, virtual] |
Begin benchmarking.
The total number of benchmarks registred is the sum of the two counts passed to the outputter.
| enabledCount | Number of benchmarks to be executed. |
| disabledCount | Number of disabled benchmarks to be skipped. |
Implements hayai::Outputter.
Definition at line 70 of file hayai_junit_xml_outputter.hpp.
| virtual void hayai::JUnitXmlOutputter::BeginTest | ( | const std::string & | fixtureName, |
| const std::string & | testName, | ||
| const TestParametersDescriptor & | parameters, | ||
| const std::size_t & | runsCount, | ||
| const std::size_t & | iterationsCount | ||
| ) | [inline, virtual] |
Begin benchmark test run.
| fixtureName | Fixture name. |
| testName | Test name. |
| parameters | Test parameter description. |
| runsCount | Number of runs to be executed. |
| iterationsCount | Number of iterations per run. |
Implements hayai::Outputter.
Definition at line 126 of file hayai_junit_xml_outputter.hpp.
| virtual void hayai::JUnitXmlOutputter::End | ( | const std::size_t & | executedCount, |
| const std::size_t & | disabledCount | ||
| ) | [inline, virtual] |
End benchmarking.
| executedCount | Number of benchmarks that have been executed. |
| disabledCount | Number of benchmarks that have been skipped because they are disabled. |
Implements hayai::Outputter.
Definition at line 78 of file hayai_junit_xml_outputter.hpp.
| virtual void hayai::JUnitXmlOutputter::EndTest | ( | const std::string & | fixtureName, |
| const std::string & | testName, | ||
| const TestParametersDescriptor & | parameters, | ||
| const TestResult & | result | ||
| ) | [inline, virtual] |
End benchmark test run.
| fixtureName | Fixture name. |
| testName | Test name. |
| parameters | Test parameter description. |
| result | Test result. |
Implements hayai::Outputter.
Definition at line 154 of file hayai_junit_xml_outputter.hpp.
| virtual void hayai::JUnitXmlOutputter::SkipDisabledTest | ( | const std::string & | fixtureName, |
| const std::string & | testName, | ||
| const TestParametersDescriptor & | parameters, | ||
| const std::size_t & | runsCount, | ||
| const std::size_t & | iterationsCount | ||
| ) | [inline, virtual] |
Skip disabled benchmark test run.
| fixtureName | Fixture name. |
| testName | Test name. |
| parameters | Test parameter description. |
| runsCount | Number of runs to be executed. |
| iterationsCount | Number of iterations per run. |
Implements hayai::Outputter.
Definition at line 140 of file hayai_junit_xml_outputter.hpp.
| void hayai::JUnitXmlOutputter::WriteEscapedString | ( | const std::string & | str | ) | [inline, private] |
Write an escaped string.
The escaping is currently very rudimentary and assumes that names, parameters etc. are ASCII.
| str | String to write. |
Definition at line 219 of file hayai_junit_xml_outputter.hpp.
std::ostream& hayai::JUnitXmlOutputter::_stream [private] |
Definition at line 257 of file hayai_junit_xml_outputter.hpp.
Definition at line 258 of file hayai_junit_xml_outputter.hpp.