Lines Matching refs:test_case

305 static bool TestCasePassed(const TestCase* test_case) {
306 return test_case->should_run() && test_case->Passed();
310 static bool TestCaseFailed(const TestCase* test_case) {
311 return test_case->should_run() && test_case->Failed();
314 // Returns true iff test_case contains at least one test that should
316 static bool ShouldRunTestCase(const TestCase* test_case) {
317 return test_case->should_run();
1964 const TestCase* const test_case = impl->current_test_case();
1968 test_case->test_info_list().GetElement(0)->impl();
2637 static void PrintTestName(const char * test_case, const char * test) {
2638 printf("%s.%s", test_case, test);
2646 virtual void OnTestCaseStart(const TestCase& test_case);
2650 virtual void OnTestCaseEnd(const TestCase& test_case);
2704 void PrettyUnitTestResultPrinter::OnTestCaseStart(const TestCase& test_case) {
2705 test_case_name_ = test_case.name();
2707 FormatCountableNoun(test_case.test_to_run_count(), "test", "tests");
2710 if (test_case.comment()[0] == '\0') {
2713 printf(", where %s\n", test_case.comment());
2757 void PrettyUnitTestResultPrinter::OnTestCaseEnd(const TestCase& test_case) {
2760 test_case_name_ = test_case.name();
2762 FormatCountableNoun(test_case.test_to_run_count(), "test", "tests");
2766 internal::StreamableToString(test_case.elapsed_time()).c_str());
2785 const TestCase& test_case = *unit_test.GetTestCase(i);
2786 if (!test_case.should_run() || (test_case.failed_test_count() == 0)) {
2789 for (int j = 0; j < test_case.total_test_count(); ++j) {
2790 const TestInfo& test_info = *test_case.GetTestInfo(j);
2795 printf("%s.%s", test_case.name(), test_info.name());
2796 if (test_case.comment()[0] != '\0' ||
2798 printf(", where %s", test_case.comment());
2799 if (test_case.comment()[0] != '\0' &&
2868 virtual void OnTestCaseStart(const TestCase& test_case);
2872 virtual void OnTestCaseEnd(const TestCase& test_case);
3011 static void PrintXmlTestCase(FILE* out, const TestCase& test_case);
3225 const TestCase& test_case) {
3229 EscapeXmlAttribute(test_case.name()).c_str(),
3230 test_case.total_test_count(),
3231 test_case.failed_test_count(),
3232 test_case.disabled_test_count());
3235 FormatTimeInMillisAsSeconds(test_case.elapsed_time()));
3236 for (int i = 0; i < test_case.total_test_count(); ++i) {
3238 OutputXmlTestInfo(&stream, test_case.name(), *test_case.GetTestInfo(i));
3841 // Returns true iff the name of test_case matches name_.
3842 bool operator()(const TestCase* test_case) const {
3843 return test_case != NULL && strcmp(test_case->name(), name_.c_str()) == 0;
3865 TestCase** test_case = test_cases_.FindIf(TestCaseNameIs(test_case_name));
3867 if (test_case != NULL)
3868 return *test_case;
4148 TestCase* const test_case = test_cases_.GetElement(i);
4149 const String &test_case_name = test_case->name();
4150 test_case->set_should_run(false);
4152 for (int j = 0; j < test_case->test_info_list().size(); j++) {
4153 TestInfo* const test_info = test_case->test_info_list().GetElement(j);
4182 test_case->set_should_run(test_case->should_run() || is_selected);
4191 const TestCase* const test_case = test_cases_.GetElement(i);
4194 for (int j = 0; j < test_case->test_info_list().size(); j++) {
4196 test_case->test_info_list().GetElement(j);
4200 printf("%s.\n", test_case->name());