CHROMA
|
#include <gtest.h>
Public Member Functions | |
TestCase (const char *name, const char *a_type_param, Test::SetUpTestCaseFunc set_up_tc, Test::TearDownTestCaseFunc tear_down_tc) | |
virtual | ~TestCase () |
const char * | name () const |
const char * | type_param () const |
bool | should_run () const |
int | successful_test_count () const |
int | failed_test_count () const |
int | reportable_disabled_test_count () const |
int | disabled_test_count () const |
int | reportable_test_count () const |
int | test_to_run_count () const |
int | total_test_count () const |
bool | Passed () const |
bool | Failed () const |
TimeInMillis | elapsed_time () const |
const TestInfo * | GetTestInfo (int i) const |
const TestResult & | ad_hoc_test_result () const |
Private Member Functions | |
std::vector< TestInfo * > & | test_info_list () |
const std::vector< TestInfo * > & | test_info_list () const |
TestInfo * | GetMutableTestInfo (int i) |
void | set_should_run (bool should) |
void | AddTestInfo (TestInfo *test_info) |
void | ClearResult () |
void | Run () |
void | RunSetUpTestCase () |
void | RunTearDownTestCase () |
void | ShuffleTests (internal::Random *random) |
void | UnshuffleTests () |
GTEST_DISALLOW_COPY_AND_ASSIGN_ (TestCase) | |
Static Private Member Functions | |
static void | ClearTestCaseResult (TestCase *test_case) |
static bool | TestPassed (const TestInfo *test_info) |
static bool | TestFailed (const TestInfo *test_info) |
static bool | TestReportableDisabled (const TestInfo *test_info) |
static bool | TestDisabled (const TestInfo *test_info) |
static bool | TestReportable (const TestInfo *test_info) |
static bool | ShouldRunTest (const TestInfo *test_info) |
Private Attributes | |
std::string | name_ |
const internal::scoped_ptr< const ::std::string > | type_param_ |
std::vector< TestInfo * > | test_info_list_ |
std::vector< int > | test_indices_ |
Test::SetUpTestCaseFunc | set_up_tc_ |
Test::TearDownTestCaseFunc | tear_down_tc_ |
bool | should_run_ |
TimeInMillis | elapsed_time_ |
TestResult | ad_hoc_test_result_ |
Friends | |
class | Test |
class | internal::UnitTestImpl |
testing::TestCase::TestCase | ( | const char * | name, |
const char * | a_type_param, | ||
Test::SetUpTestCaseFunc | set_up_tc, | ||
Test::TearDownTestCaseFunc | tear_down_tc | ||
) |
Definition at line 3874 of file gtest-all.cc.
|
virtual |
Definition at line 3886 of file gtest-all.cc.
References testing::internal::ForEach(), and test_info_list_.
|
inline |
Definition at line 18230 of file gtest.h.
Referenced by testing::internal::XmlUnitTestResultPrinter::PrintXmlTestCase().
|
private |
Definition at line 3907 of file gtest-all.cc.
References test_indices_, and test_info_list_.
|
private |
Definition at line 3941 of file gtest-all.cc.
References ad_hoc_test_result_, testing::TestResult::Clear(), testing::TestInfo::ClearTestResult(), testing::internal::ForEach(), and test_info_list_.
Referenced by ClearTestCaseResult().
|
inlinestaticprivate |
Definition at line 18259 of file gtest.h.
References ClearResult().
Referenced by testing::internal::UnitTestImpl::ClearNonAdHocTestResult().
int testing::TestCase::disabled_test_count | ( | ) | const |
Definition at line 3846 of file gtest-all.cc.
References testing::internal::CountIf(), test_info_list_, and TestDisabled().
Referenced by testing::internal::UnitTestImpl::disabled_test_count().
|
inline |
Definition at line 18222 of file gtest.h.
Referenced by testing::internal::PrettyUnitTestResultPrinter::OnTestCaseEnd(), and testing::internal::XmlUnitTestResultPrinter::PrintXmlTestCase().
|
inline |
Definition at line 18219 of file gtest.h.
Referenced by testing::internal::TestCaseFailed().
int testing::TestCase::failed_test_count | ( | ) | const |
Definition at line 3836 of file gtest-all.cc.
References testing::internal::CountIf(), test_info_list_, and TestFailed().
Referenced by testing::internal::UnitTestImpl::failed_test_count(), testing::internal::PrettyUnitTestResultPrinter::PrintFailedTests(), and testing::internal::XmlUnitTestResultPrinter::PrintXmlTestCase().
|
private |
Definition at line 3900 of file gtest-all.cc.
References testing::internal::GetElementOr(), i, index, test_indices_, and test_info_list_.
Referenced by Run().
const TestInfo * testing::TestCase::GetTestInfo | ( | int | i | ) | const |
Definition at line 3893 of file gtest-all.cc.
References testing::internal::GetElementOr(), i, index, test_indices_, and test_info_list_.
Referenced by testing::internal::PrettyUnitTestResultPrinter::PrintFailedTests(), and testing::internal::XmlUnitTestResultPrinter::PrintXmlTestCase().
|
private |
|
inline |
Definition at line 18181 of file gtest.h.
References name_.
Referenced by testing::internal::UnitTestImpl::FilterTests(), testing::internal::UnitTestImpl::ListTestsMatchingFilter(), testing::internal::PrettyUnitTestResultPrinter::OnTestCaseEnd(), testing::internal::PrettyUnitTestResultPrinter::OnTestCaseStart(), testing::internal::TestCaseNameIs::operator()(), testing::internal::PrettyUnitTestResultPrinter::PrintFailedTests(), and testing::internal::XmlUnitTestResultPrinter::PrintXmlTestCase().
|
inline |
Definition at line 18216 of file gtest.h.
Referenced by testing::internal::TestCasePassed().
int testing::TestCase::reportable_disabled_test_count | ( | ) | const |
Definition at line 3841 of file gtest-all.cc.
References testing::internal::CountIf(), test_info_list_, and TestReportableDisabled().
Referenced by testing::internal::XmlUnitTestResultPrinter::PrintXmlTestCase(), and testing::internal::UnitTestImpl::reportable_disabled_test_count().
int testing::TestCase::reportable_test_count | ( | ) | const |
Definition at line 3851 of file gtest-all.cc.
References testing::internal::CountIf(), test_info_list_, and TestReportable().
Referenced by testing::internal::XmlUnitTestResultPrinter::PrintXmlTestCase(), testing::internal::XmlUnitTestResultPrinter::PrintXmlUnitTest(), and testing::internal::UnitTestImpl::reportable_test_count().
|
private |
Definition at line 3913 of file gtest-all.cc.
References elapsed_time_, testing::UnitTest::GetInstance(), GetMutableTestInfo(), testing::internal::GetTimeInMillis(), testing::internal::GetUnitTestImpl(), testing::internal::HandleExceptionsInMethodIfSupported(), i, testing::UnitTest::listeners(), testing::TestEventListener::OnTestCaseEnd(), testing::TestEventListener::OnTestCaseStart(), testing::internal::UnitTestImpl::os_stack_trace_getter(), testing::TestEventListeners::repeater(), testing::TestInfo::Run(), RunSetUpTestCase(), RunTearDownTestCase(), testing::internal::UnitTestImpl::set_current_test_case(), should_run_, total_test_count(), and testing::internal::OsStackTraceGetterInterface::UponLeavingGTest().
Referenced by testing::internal::UnitTestImpl::RunAllTests().
|
inlineprivate |
|
inlineprivate |
|
inlineprivate |
Definition at line 18249 of file gtest.h.
Referenced by testing::internal::UnitTestImpl::FilterTests().
|
inline |
|
inlinestaticprivate |
Definition at line 18301 of file gtest.h.
References testing::TestInfo::should_run().
Referenced by test_to_run_count().
|
private |
Definition at line 3947 of file gtest-all.cc.
References testing::internal::Shuffle(), and test_indices_.
int testing::TestCase::successful_test_count | ( | ) | const |
Definition at line 3831 of file gtest-all.cc.
References testing::internal::CountIf(), test_info_list_, and TestPassed().
Referenced by testing::internal::UnitTestImpl::successful_test_count().
|
inlineprivate |
Definition at line 18237 of file gtest.h.
Referenced by testing::internal::UnitTestImpl::FilterTests(), testing::Test::HasSameFixtureClass(), and testing::internal::UnitTestImpl::ListTestsMatchingFilter().
|
inlineprivate |
int testing::TestCase::test_to_run_count | ( | ) | const |
Definition at line 3856 of file gtest-all.cc.
References testing::internal::CountIf(), ShouldRunTest(), and test_info_list_.
Referenced by testing::internal::PrettyUnitTestResultPrinter::OnTestCaseEnd(), testing::internal::PrettyUnitTestResultPrinter::OnTestCaseStart(), and testing::internal::UnitTestImpl::test_to_run_count().
|
inlinestaticprivate |
Definition at line 18291 of file gtest.h.
References testing::TestInfo::is_disabled_.
Referenced by disabled_test_count().
|
inlinestaticprivate |
Definition at line 18280 of file gtest.h.
References testing::TestResult::Failed(), testing::TestInfo::result(), and testing::TestInfo::should_run().
Referenced by failed_test_count().
|
inlinestaticprivate |
Definition at line 18275 of file gtest.h.
References testing::TestResult::Passed(), testing::TestInfo::result(), and testing::TestInfo::should_run().
Referenced by successful_test_count().
|
inlinestaticprivate |
Definition at line 18296 of file gtest.h.
References testing::TestInfo::is_reportable().
Referenced by reportable_test_count().
|
inlinestaticprivate |
Definition at line 18286 of file gtest.h.
References testing::TestInfo::is_disabled_, and testing::TestInfo::is_reportable().
Referenced by reportable_disabled_test_count().
int testing::TestCase::total_test_count | ( | ) | const |
Definition at line 3861 of file gtest-all.cc.
References test_info_list_.
Referenced by testing::internal::PrettyUnitTestResultPrinter::PrintFailedTests(), testing::internal::XmlUnitTestResultPrinter::PrintXmlTestCase(), Run(), and testing::internal::UnitTestImpl::total_test_count().
|
inline |
Definition at line 18185 of file gtest.h.
Referenced by testing::internal::UnitTestImpl::ListTestsMatchingFilter(), and testing::internal::PrettyUnitTestResultPrinter::OnTestCaseStart().
|
private |
Definition at line 3952 of file gtest-all.cc.
References i, and test_indices_.
|
friend |
|
private |
Definition at line 18333 of file gtest.h.
Referenced by ClearResult(), and testing::internal::UnitTestImpl::RecordProperty().
|
private |
|
private |
|
private |
|
private |
|
private |
Definition at line 18322 of file gtest.h.
Referenced by AddTestInfo(), GetMutableTestInfo(), GetTestInfo(), ShuffleTests(), and UnshuffleTests().
|
private |
Definition at line 18318 of file gtest.h.
Referenced by AddTestInfo(), ClearResult(), disabled_test_count(), failed_test_count(), GetMutableTestInfo(), GetTestInfo(), reportable_disabled_test_count(), reportable_test_count(), successful_test_count(), test_to_run_count(), total_test_count(), and ~TestCase().
|
private |