MCPcopy Create free account
hub / github.com/EmbeddedRPC/erpc / TestPartResultTypeToString

Function TestPartResultTypeToString

test/common/gtest/gtest.cpp:4270–4285  ·  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

4268// to "Failure", as the user usually doesn't care about the difference
4269// between the two when viewing the test result.
4270static const char * TestPartResultTypeToString(TestPartResult::Type type) {
4271 switch (type) {
4272 case TestPartResult::kSuccess:
4273 return "Success";
4274
4275 case TestPartResult::kNonFatalFailure:
4276 case TestPartResult::kFatalFailure:
4277#ifdef _MSC_VER
4278 return "error: ";
4279#else
4280 return "Failure\n";
4281#endif
4282 default:
4283 return "Unknown result type";
4284 }
4285}
4286
4287namespace internal {
4288

Callers 1

Calls

no outgoing calls

Tested by

no test coverage detected