MCPcopy Create free account
hub / github.com/apache/singa / TestPartResultTypeToString

Function TestPartResultTypeToString

test/gtest/gtest-all.cc:3984–3999  ·  view source on GitHub ↗

Converts a TestPartResult::Type enum to human-friendly string representation. Both kNonFatalFailure and kFatalFailure are translated to "Failure", as the user usually doesn't care about the difference between the two when viewing the test result.

Source from the content-addressed store, hash-verified

3982// to "Failure", as the user usually doesn't care about the difference
3983// between the two when viewing the test result.
3984static const char * TestPartResultTypeToString(TestPartResult::Type type) {
3985 switch (type) {
3986 case TestPartResult::kSuccess:
3987 return "Success";
3988
3989 case TestPartResult::kNonFatalFailure:
3990 case TestPartResult::kFatalFailure:
3991#ifdef _MSC_VER
3992 return "error: ";
3993#else
3994 return "Failure\n";
3995#endif
3996 default:
3997 return "Unknown result type";
3998 }
3999}
4000
4001namespace internal {
4002

Callers 1

Calls

no outgoing calls

Tested by

no test coverage detected