MCPcopy Create free account
hub / github.com/Pagghiu/SaneCppLibraries / ~TestCase

Method ~TestCase

Libraries/Testing/Testing.cpp:715–749  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

713}
714
715SC::TestCase::~TestCase()
716{
717 if (report.isTestEnabled(testName))
718 {
719 if (not printedSection and not report.currentSection.isEmpty())
720 {
721 report.printSectionResult(*this);
722 }
723 if (not report.quietMode)
724 {
725 report.console.print("\n");
726 if (numTestsFailed > 0)
727 {
728 report.console.print(redEMOJI);
729 report.console.print(" [[ ");
730 report.console.print(testName);
731 report.console.print(" ]]");
732 report.console.print(" FAILED = {} (Succeeded = {})\n", numTestsFailed, numTestsSucceeded);
733 }
734 else
735 {
736 report.console.print(greenEMOJI);
737 report.console.print(" [[ ");
738 report.console.print(testName);
739 report.console.print(" ]]");
740 report.console.print(" SUCCEEDED = {}\n", numTestsSucceeded);
741 }
742 report.console.print("---------------------------------------------------\n");
743 }
744 report.console.flush();
745 report.numTestsFailed += numTestsFailed;
746 report.numTestsSucceeded += numTestsSucceeded;
747 report.testCaseFinished(*this);
748 }
749}
750
751bool SC::TestCase::recordExpectation(StringSpan expression, bool status, StringSpan detailedError)
752{

Callers

nothing calls this directly

Calls 6

isTestEnabledMethod · 0.80
printSectionResultMethod · 0.80
printMethod · 0.80
flushMethod · 0.80
testCaseFinishedMethod · 0.80
isEmptyMethod · 0.45

Tested by

no test coverage detected