33 #ifndef GTEST_INCLUDE_GTEST_GTEST_TEST_PART_H_ 34 #define GTEST_INCLUDE_GTEST_GTEST_TEST_PART_H_ 61 const char* a_file_name,
63 const char* a_message)
65 file_name_(a_file_name == NULL ?
"" : a_file_name),
66 line_number_(a_line_number),
67 summary_(ExtractSummary(a_message)),
77 return file_name_.empty() ? NULL : file_name_.c_str();
85 const char*
summary()
const {
return summary_.c_str(); }
88 const char*
message()
const {
return message_.c_str(); }
91 bool passed()
const {
return type_ == kSuccess; }
94 bool failed()
const {
return type_ != kSuccess; }
107 static std::string ExtractSummary(
const char* message);
140 std::vector<TestPartResult> array_;
150 virtual void ReportTestPartResult(
const TestPartResult& result) = 0;
169 bool has_new_fatal_failure_;
179 #endif // GTEST_INCLUDE_GTEST_GTEST_TEST_PART_H_ bool has_new_fatal_failure() const
bool fatally_failed() const
const char * summary() const
const char * message() const
virtual ~TestPartResultReporterInterface()
TestPartResult(Type a_type, const char *a_file_name, int a_line_number, const char *a_message)
std::ostream & operator<<(std::ostream &os, const Message &sb)
const char * file_name() const
#define GTEST_DISALLOW_COPY_AND_ASSIGN_(type)
bool nonfatally_failed() const