Definition at line 52 of file gtest-unittest-api_test.cc.
◆ FindTestSuite()
static const TestSuite * testing::internal::UnitTestHelper::FindTestSuite |
( |
const char * |
name | ) |
|
|
inlinestatic |
Definition at line 72 of file gtest-unittest-api_test.cc.
72 {
74 for (
int i = 0;
i < unit_test.total_test_suite_count(); ++
i) {
75 const TestSuite* test_suite = unit_test.GetTestSuite(
i);
76 if (0 == strcmp(test_suite->name(), name))
77 return test_suite;
78 }
79 return nullptr;
80 }
static UnitTest * GetInstance()
◆ GetSortedTests()
static TestInfo const ** testing::internal::UnitTestHelper::GetSortedTests |
( |
const TestSuite * |
test_suite | ) |
|
|
inlinestatic |
Definition at line 85 of file gtest-unittest-api_test.cc.
85 {
86 TestInfo const** const tests = new const TestInfo*[static_cast<size_t>(
87 test_suite->total_test_count())];
88
89 for (
int i = 0;
i < test_suite->total_test_count(); ++
i)
90 tests[
i] = test_suite->GetTestInfo(
i);
91
92 std::sort(tests, tests + test_suite->total_test_count(),
93 LessByName<TestInfo>());
94 return tests;
95 }
◆ GetSortedTestSuites()
static TestSuite const ** testing::internal::UnitTestHelper::GetSortedTestSuites |
( |
| ) |
|
|
inlinestatic |
Definition at line 56 of file gtest-unittest-api_test.cc.
56 {
58 auto const** const test_suites = new const TestSuite*[static_cast<size_t>(
59 unit_test.total_test_suite_count())];
60
61 for (
int i = 0;
i < unit_test.total_test_suite_count(); ++
i)
62 test_suites[
i] = unit_test.GetTestSuite(
i);
63
64 std::sort(test_suites,
65 test_suites + unit_test.total_test_suite_count(),
66 LessByName<TestSuite>());
67 return test_suites;
68 }
The documentation for this class was generated from the following file: