void TextTestResult::printHeader(std::ostream& stream) { stream << "\n\n"; if (wasSuccessful()) stream << "OK (" << runTests() << " tests)" << std::endl; else stream << "!!!FAILURES!!!" << std::endl << "Runs: " << runTests () << " Failures: " << testFailures () << " Errors: " << testErrors () << std::endl; }
void TextTestResult::printHeader (std::ostream &stream) { if (wasSuccessful ()) std::cout << "OK (" << runTests () << " tests and " << testSuccesses() << " assertions in " << elapsedTime() << " ms)" << std::endl; else std::cout << std::endl << "!!!FAILURES!!!" << std::endl << "Test Results:" << std::endl << "Run: " << runTests () << " Failures: " << testFailures () << " Errors: " << testErrors () << std::endl << "(" << testSuccesses() << " assertions ran successfully in " << elapsedTime() << " ms)" << std::endl; }