tesseract v5.3.3.20231005
Predicate2Test Class Reference
Inheritance diagram for Predicate2Test:
testing::Test

Protected Member Functions

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

Static Protected Attributes

static bool expected_to_finish_
 
static bool finished_
 
static int n1_
 
static int n2_
 

Additional Inherited Members

- Public Member Functions inherited from testing::Test
virtual ~Test ()
 
- Static Public Member Functions inherited from testing::Test
static void SetUpTestSuite ()
 
static void TearDownTestSuite ()
 
static void TearDownTestCase ()
 
static void SetUpTestCase ()
 
static bool HasFatalFailure ()
 
static bool HasNonfatalFailure ()
 
static bool IsSkipped ()
 
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 513 of file gtest_pred_impl_unittest.cc.

Member Function Documentation

◆ SetUp()

void Predicate2Test::SetUp ( )
inlineoverrideprotectedvirtual

Reimplemented from testing::Test.

Definition at line 515 of file gtest_pred_impl_unittest.cc.

515 {
516 expected_to_finish_ = true;
517 finished_ = false;
518 n1_ = n2_ = 0;
519 }

◆ TearDown()

void Predicate2Test::TearDown ( )
inlineoverrideprotectedvirtual

Reimplemented from testing::Test.

Definition at line 521 of file gtest_pred_impl_unittest.cc.

521 {
522 // Verifies that each of the predicate's arguments was evaluated
523 // exactly once.
524 EXPECT_EQ(1, n1_) <<
525 "The predicate assertion didn't evaluate argument 2 "
526 "exactly once.";
527 EXPECT_EQ(1, n2_) <<
528 "The predicate assertion didn't evaluate argument 3 "
529 "exactly once.";
530
531 // Verifies that the control flow in the test function is expected.
533 FAIL() << "The predicate assertion unexpactedly aborted the test.";
534 } else if (!expected_to_finish_ && finished_) {
535 FAIL() << "The failed predicate assertion didn't abort the test "
536 "as expected.";
537 }
538 }
#define FAIL()
Definition: gtest.h:1928
#define EXPECT_EQ(val1, val2)
Definition: gtest.h:2043

Member Data Documentation

◆ expected_to_finish_

bool Predicate2Test::expected_to_finish_
staticprotected

Definition at line 541 of file gtest_pred_impl_unittest.cc.

◆ finished_

bool Predicate2Test::finished_
staticprotected

Definition at line 544 of file gtest_pred_impl_unittest.cc.

◆ n1_

int Predicate2Test::n1_
staticprotected

Definition at line 546 of file gtest_pred_impl_unittest.cc.

◆ n2_

int Predicate2Test::n2_
staticprotected

Definition at line 547 of file gtest_pred_impl_unittest.cc.


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