49 return strcmp(a->name(), b->name()) < 0;
77 if (0 == strcmp(test_case->
name(),
name))
99 #if GTEST_HAS_TYPED_TEST
100 template <
typename T>
class TestCaseWithCommentTest :
public Test {};
109 #endif // GTEST_HAS_TYPED_TEST
114 TEST(ApiTest, UnitTestImmutableAccessorsWork) {
127 #if GTEST_HAS_TYPED_TEST
129 #endif // GTEST_HAS_TYPED_TEST
137 RecordProperty(
"key",
"value");
147 TEST(ApiTest, TestCaseImmutableAccessorsWork) {
187 #if GTEST_HAS_TYPED_TEST
201 EXPECT_STREQ(
"TestCaseWithCommentTest/0", tests[0]->test_case_name());
203 EXPECT_STREQ(GetTypeName<int>().c_str(), tests[0]->type_param());
207 #endif // GTEST_HAS_TYPED_TEST
210 TEST(ApiTest, TestCaseDisabledAccessorsWork) {
223 EXPECT_STREQ(
"DISABLED_Test", test_info->test_case_name());
231 TEST(ApiTest, DISABLED_Dummy1) {}
252 EXPECT_EQ(1, test_cases[0]->disabled_test_count());
253 ASSERT_EQ(4, test_cases[0]->total_test_count());
254 EXPECT_EQ(3, test_cases[0]->successful_test_count());
255 EXPECT_EQ(0, test_cases[0]->failed_test_count());
262 EXPECT_EQ(1, test_cases[1]->disabled_test_count());
263 ASSERT_EQ(1, test_cases[1]->total_test_count());
264 EXPECT_EQ(0, test_cases[1]->successful_test_count());
265 EXPECT_EQ(0, test_cases[1]->failed_test_count());
267 #if GTEST_HAS_TYPED_TEST
269 EXPECT_STREQ(GetTypeName<int>().c_str(), test_cases[2]->type_param());
271 EXPECT_EQ(0, test_cases[2]->disabled_test_count());
272 ASSERT_EQ(1, test_cases[2]->total_test_count());
273 EXPECT_EQ(1, test_cases[2]->successful_test_count());
274 EXPECT_EQ(0, test_cases[2]->failed_test_count());
277 #endif // GTEST_HAS_TYPED_TEST
291 EXPECT_EQ(0, tests[1]->result()->test_property_count());
299 EXPECT_EQ(0, tests[2]->result()->test_property_count());
307 EXPECT_EQ(1, tests[3]->result()->test_property_count());
314 #if GTEST_HAS_TYPED_TEST
319 EXPECT_STREQ(
"TestCaseWithCommentTest/0", tests[0]->test_case_name());
321 EXPECT_STREQ(GetTypeName<int>().c_str(), tests[0]->type_param());
324 EXPECT_EQ(0, tests[0]->result()->test_property_count());
327 #endif // GTEST_HAS_TYPED_TEST
335 int main(
int argc,
char **argv) {