MCPcopy Create free account
hub / github.com/RenderKit/embree / writeGroup

Method writeGroup

tutorials/external/catch.hpp:14099–14135  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

14097 }
14098
14099 void JunitReporter::writeGroup( TestGroupNode const& groupNode, double suiteTime ) {
14100 XmlWriter::ScopedElement e = xml.scopedElement( "testsuite" );
14101
14102 TestGroupStats const& stats = groupNode.value;
14103 xml.writeAttribute( "name", stats.groupInfo.name );
14104 xml.writeAttribute( "errors", unexpectedExceptions );
14105 xml.writeAttribute( "failures", stats.totals.assertions.failed-unexpectedExceptions );
14106 xml.writeAttribute( "tests", stats.totals.assertions.total() );
14107 xml.writeAttribute( "hostname", "tbd" ); // !TBD
14108 if( m_config->showDurations() == ShowDurations::Never )
14109 xml.writeAttribute( "time", "" );
14110 else
14111 xml.writeAttribute( "time", suiteTime );
14112 xml.writeAttribute( "timestamp", getCurrentTimestamp() );
14113
14114 // Write properties if there are any
14115 if (m_config->hasTestFilters() || m_config->rngSeed() != 0) {
14116 auto properties = xml.scopedElement("properties");
14117 if (m_config->hasTestFilters()) {
14118 xml.scopedElement("property")
14119 .writeAttribute("name", "filters")
14120 .writeAttribute("value", serializeFilters(m_config->getTestsOrTags()));
14121 }
14122 if (m_config->rngSeed() != 0) {
14123 xml.scopedElement("property")
14124 .writeAttribute("name", "random-seed")
14125 .writeAttribute("value", m_config->rngSeed());
14126 }
14127 }
14128
14129 // Write test cases
14130 for( auto const& child : groupNode.children )
14131 writeTestCase( *child );
14132
14133 xml.scopedElement( "system-out" ).writeText( trim( stdOutForSuite ), false );
14134 xml.scopedElement( "system-err" ).writeText( trim( stdErrForSuite ), false );
14135 }
14136
14137 void JunitReporter::writeTestCase( TestCaseNode const& testCaseNode ) {
14138 TestCaseStats const& stats = testCaseNode.value;

Callers

nothing calls this directly

Calls 8

getCurrentTimestampFunction · 0.85
serializeFiltersFunction · 0.85
trimFunction · 0.85
scopedElementMethod · 0.80
totalMethod · 0.80
showDurationsMethod · 0.80
hasTestFiltersMethod · 0.80
rngSeedMethod · 0.80

Tested by

no test coverage detected