MCPcopy Create free account
hub / github.com/CodingGay/BlackDex / writeTestCase

Method writeTestCase

Bcore/src/main/cpp/Dobby/tests/catch.hpp:12194–12214  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

12192}
12193
12194void JunitReporter::writeTestCase(TestCaseNode const &testCaseNode) {
12195 TestCaseStats const &stats = testCaseNode.value;
12196
12197 // All test cases have exactly one section - which represents the
12198 // test case itself. That section may have 0-n nested sections
12199 assert(testCaseNode.children.size() == 1);
12200 SectionNode const &rootSection = *testCaseNode.children.front();
12201
12202 std::string className = stats.testInfo.className;
12203
12204 if (className.empty()) {
12205 className = fileNameTag(stats.testInfo.tags);
12206 if (className.empty())
12207 className = "global";
12208 }
12209
12210 if (!m_config->name().empty())
12211 className = m_config->name() + "." + className;
12212
12213 writeSection(className, "", rootSection);
12214}
12215
12216void JunitReporter::writeSection(std::string const &className, std::string const &rootName,
12217 SectionNode const &sectionNode) {

Callers

nothing calls this directly

Calls 4

fileNameTagFunction · 0.85
sizeMethod · 0.45
emptyMethod · 0.45
nameMethod · 0.45

Tested by

no test coverage detected