proxygen
QuickTest Class Reference
Inheritance diagram for QuickTest:
testing::Test testing::Test testing::Test IntegerFunctionTest IntegerFunctionTest IntegerFunctionTest QueueTest QueueTest QueueTest

Protected Member Functions

virtual void SetUp ()
 
virtual void TearDown ()
 
virtual void SetUp ()
 
virtual void TearDown ()
 
virtual void SetUp ()
 
virtual void TearDown ()
 
- Protected Member Functions inherited from testing::Test
 Test ()
 
 Test ()
 
 Test ()
 

Protected Attributes

time_t start_time_
 

Additional Inherited Members

- Public Types inherited from testing::Test
typedef internal::SetUpTestCaseFunc SetUpTestCaseFunc
 
typedef internal::TearDownTestCaseFunc TearDownTestCaseFunc
 
typedef internal::SetUpTestCaseFunc SetUpTestCaseFunc
 
typedef internal::TearDownTestCaseFunc TearDownTestCaseFunc
 
typedef internal::SetUpTestCaseFunc SetUpTestCaseFunc
 
typedef internal::TearDownTestCaseFunc TearDownTestCaseFunc
 
- Public Member Functions inherited from testing::Test
virtual ~Test ()
 
virtual ~Test ()
 
virtual ~Test ()
 
- Static Public Member Functions inherited from testing::Test
static void SetUpTestCase ()
 
static void TearDownTestCase ()
 
static bool HasFatalFailure ()
 
static bool HasNonfatalFailure ()
 
static bool HasFailure ()
 
static void RecordProperty (const std::string &key, const std::string &value)
 
static void RecordProperty (const std::string &key, int value)
 
static void SetUpTestCase ()
 
static void TearDownTestCase ()
 
static bool HasFatalFailure ()
 
static bool HasNonfatalFailure ()
 
static bool HasFailure ()
 
static void RecordProperty (const std::string &key, const std::string &value)
 
static void RecordProperty (const std::string &key, int value)
 
static void SetUpTestCase ()
 
static void TearDownTestCase ()
 
static bool HasFatalFailure ()
 
static bool HasNonfatalFailure ()
 
static bool HasFailure ()
 
static void RecordProperty (const std::string &key, const std::string &value)
 
static void RecordProperty (const std::string &key, int value)
 

Detailed Description

Definition at line 63 of file sample5_unittest.cc.

Member Function Documentation

virtual void QuickTest::SetUp ( )
inlineprotectedvirtual

Reimplemented from testing::Test.

Reimplemented in QueueTest, QueueTest, QueueTest, QueueTest, QueueTest, and QueueTest.

Definition at line 67 of file sample5_unittest.cc.

References start_time_, and folly::detail::distributed_mutex::time().

Referenced by QueueTest::SetUp().

67  {
68  start_time_ = time(NULL);
69  }
time_t start_time_
std::chrono::nanoseconds time()
virtual void QuickTest::SetUp ( )
inlineprotectedvirtual

Reimplemented from testing::Test.

Reimplemented in QueueTest, QueueTest, QueueTest, QueueTest, QueueTest, and QueueTest.

Definition at line 67 of file sample5_unittest.cc.

References start_time_, and folly::detail::distributed_mutex::time().

67  {
68  start_time_ = time(NULL);
69  }
time_t start_time_
std::chrono::nanoseconds time()
virtual void QuickTest::SetUp ( )
inlineprotectedvirtual

Reimplemented from testing::Test.

Reimplemented in QueueTest, QueueTest, QueueTest, QueueTest, QueueTest, and QueueTest.

Definition at line 67 of file sample5_unittest.cc.

References start_time_, and folly::detail::distributed_mutex::time().

67  {
68  start_time_ = time(NULL);
69  }
time_t start_time_
std::chrono::nanoseconds time()
virtual void QuickTest::TearDown ( )
inlineprotectedvirtual

Reimplemented from testing::Test.

Definition at line 73 of file sample5_unittest.cc.

References EXPECT_TRUE, start_time_, and folly::detail::distributed_mutex::time().

73  {
74  // Gets the time when the test finishes
75  const time_t end_time = time(NULL);
76 
77  // Asserts that the test took no more than ~5 seconds. Did you
78  // know that you can use assertions in SetUp() and TearDown() as
79  // well?
80  EXPECT_TRUE(end_time - start_time_ <= 5) << "The test took too long.";
81  }
time_t start_time_
#define EXPECT_TRUE(condition)
Definition: gtest.h:1859
std::chrono::nanoseconds time()
virtual void QuickTest::TearDown ( )
inlineprotectedvirtual

Reimplemented from testing::Test.

Definition at line 73 of file sample5_unittest.cc.

References EXPECT_TRUE, start_time_, and folly::detail::distributed_mutex::time().

73  {
74  // Gets the time when the test finishes
75  const time_t end_time = time(NULL);
76 
77  // Asserts that the test took no more than ~5 seconds. Did you
78  // know that you can use assertions in SetUp() and TearDown() as
79  // well?
80  EXPECT_TRUE(end_time - start_time_ <= 5) << "The test took too long.";
81  }
time_t start_time_
#define EXPECT_TRUE(condition)
Definition: gtest.h:1859
std::chrono::nanoseconds time()
virtual void QuickTest::TearDown ( )
inlineprotectedvirtual

Reimplemented from testing::Test.

Definition at line 73 of file sample5_unittest.cc.

References EXPECT_TRUE, start_time_, and folly::detail::distributed_mutex::time().

73  {
74  // Gets the time when the test finishes
75  const time_t end_time = time(NULL);
76 
77  // Asserts that the test took no more than ~5 seconds. Did you
78  // know that you can use assertions in SetUp() and TearDown() as
79  // well?
80  EXPECT_TRUE(end_time - start_time_ <= 5) << "The test took too long.";
81  }
time_t start_time_
#define EXPECT_TRUE(condition)
Definition: gtest.h:1859
std::chrono::nanoseconds time()

Member Data Documentation

time_t QuickTest::start_time_
protected

Definition at line 84 of file sample5_unittest.cc.

Referenced by SetUp(), and TearDown().


The documentation for this class was generated from the following file: