Public Member Functions | List of all members
googletest-filter-unittest.GTestFilterUnitTest Class Reference
Inheritance diagram for googletest-filter-unittest.GTestFilterUnitTest:
Inheritance graph
[legend]

Public Member Functions

def AdjustForParameterizedTests (self, tests_to_run)
 
def AssertPartitionIsValid (self, set_var, list_of_sets)
 
def AssertSetEqual (self, lhs, rhs)
 
def RunAndVerify (self, gtest_filter, tests_to_run)
 
def RunAndVerifyAllowingDisabled (self, gtest_filter, tests_to_run)
 
def RunAndVerifyWithSharding (self, gtest_filter, total_shards, tests_to_run, args=None, check_exit_0=False)
 
def setUp (self)
 
def testBadFilter (self)
 
def testDefaultBehavior (self)
 
def testDefaultBehaviorWithShards (self)
 
def testEmptyFilter (self)
 
def testFilterByTest (self)
 
def testFilterByTestCase (self)
 
def testFilterDisabledTests (self)
 
def testFilterWithoutDot (self)
 
def testFlagOverridesEnvVar (self)
 
def testFullName (self)
 
def testNegativeFilters (self)
 
def testShardingWorksWithDeathTests (self)
 
def testShardStatusFileIsCreated (self)
 
def testShardStatusFileIsCreatedWithListTests (self)
 
def testThreePatterns (self)
 
def testTwoPatterns (self)
 
def testUniversalFilters (self)
 
def testWildcardInTestCaseName (self)
 
def testWildcardInTestName (self)
 

Detailed Description

Tests the env variable or the command line flag to filter tests.

Definition at line 230 of file googletest-filter-unittest.py.

Member Function Documentation

◆ AdjustForParameterizedTests()

def googletest-filter-unittest.GTestFilterUnitTest.AdjustForParameterizedTests (   self,
  tests_to_run 
)
Adjust tests_to_run in case value parameterized tests are disabled.

Definition at line 253 of file googletest-filter-unittest.py.

◆ AssertPartitionIsValid()

def googletest-filter-unittest.GTestFilterUnitTest.AssertPartitionIsValid (   self,
  set_var,
  list_of_sets 
)
Asserts that list_of_sets is a valid partition of set_var.

Definition at line 244 of file googletest-filter-unittest.py.

◆ AssertSetEqual()

def googletest-filter-unittest.GTestFilterUnitTest.AssertSetEqual (   self,
  lhs,
  rhs 
)
Asserts that two sets are equal.

Definition at line 235 of file googletest-filter-unittest.py.

◆ RunAndVerify()

def googletest-filter-unittest.GTestFilterUnitTest.RunAndVerify (   self,
  gtest_filter,
  tests_to_run 
)
Checks that the binary runs correct set of tests for a given filter.

Definition at line 262 of file googletest-filter-unittest.py.

◆ RunAndVerifyAllowingDisabled()

def googletest-filter-unittest.GTestFilterUnitTest.RunAndVerifyAllowingDisabled (   self,
  gtest_filter,
  tests_to_run 
)
Checks that the binary runs correct set of tests for the given filter.

Runs googletest-filter-unittest_ with the given filter, and enables
disabled tests. Verifies that the right set of tests were run.

Args:
  gtest_filter: A filter to apply to the tests.
  tests_to_run: A set of tests expected to run.

Definition at line 331 of file googletest-filter-unittest.py.

◆ RunAndVerifyWithSharding()

def googletest-filter-unittest.GTestFilterUnitTest.RunAndVerifyWithSharding (   self,
  gtest_filter,
  total_shards,
  tests_to_run,
  args = None,
  check_exit_0 = False 
)
Checks that binary runs correct tests for the given filter and shard.

Runs all shards of googletest-filter-unittest_ with the given filter, and
verifies that the right set of tests were run. The union of tests run
on each shard should be identical to tests_to_run, without duplicates.
If check_exit_0, .

Args:
  gtest_filter: A filter to apply to the tests.
  total_shards: A total number of shards to split test run into.
  tests_to_run: A set of tests expected to run.
  args   :      Arguments to pass to the to the test binary.
  check_exit_0: When set to a true value, make sure that all shards
            return 0.

Definition at line 292 of file googletest-filter-unittest.py.

◆ setUp()

def googletest-filter-unittest.GTestFilterUnitTest.setUp (   self)
Sets up test case.

Determines whether value-parameterized tests are enabled in the binary and
sets the flags accordingly.

Definition at line 352 of file googletest-filter-unittest.py.

◆ testBadFilter()

def googletest-filter-unittest.GTestFilterUnitTest.testBadFilter (   self)
Tests a filter that matches nothing.

Definition at line 385 of file googletest-filter-unittest.py.

◆ testDefaultBehavior()

def googletest-filter-unittest.GTestFilterUnitTest.testDefaultBehavior (   self)
Tests the behavior of not specifying the filter.

Definition at line 364 of file googletest-filter-unittest.py.

◆ testDefaultBehaviorWithShards()

def googletest-filter-unittest.GTestFilterUnitTest.testDefaultBehaviorWithShards (   self)
Tests the behavior without the filter, with sharding enabled.

Definition at line 369 of file googletest-filter-unittest.py.

◆ testEmptyFilter()

def googletest-filter-unittest.GTestFilterUnitTest.testEmptyFilter (   self)
Tests an empty filter.

Definition at line 378 of file googletest-filter-unittest.py.

◆ testFilterByTest()

def googletest-filter-unittest.GTestFilterUnitTest.testFilterByTest (   self)
Tests filtering by test name.

Definition at line 417 of file googletest-filter-unittest.py.

◆ testFilterByTestCase()

def googletest-filter-unittest.GTestFilterUnitTest.testFilterByTestCase (   self)
Tests filtering by test case name.

Definition at line 407 of file googletest-filter-unittest.py.

◆ testFilterDisabledTests()

def googletest-filter-unittest.GTestFilterUnitTest.testFilterDisabledTests (   self)
Select only the disabled tests to run.

Definition at line 422 of file googletest-filter-unittest.py.

◆ testFilterWithoutDot()

def googletest-filter-unittest.GTestFilterUnitTest.testFilterWithoutDot (   self)
Tests a filter that has no '.' in it.

Definition at line 464 of file googletest-filter-unittest.py.

◆ testFlagOverridesEnvVar()

def googletest-filter-unittest.GTestFilterUnitTest.testFlagOverridesEnvVar (   self)
Tests that the filter flag overrides the filtering env. variable.

Definition at line 569 of file googletest-filter-unittest.py.

◆ testFullName()

def googletest-filter-unittest.GTestFilterUnitTest.testFullName (   self)
Tests filtering by full name.

Definition at line 391 of file googletest-filter-unittest.py.

◆ testNegativeFilters()

def googletest-filter-unittest.GTestFilterUnitTest.testNegativeFilters (   self)

Definition at line 517 of file googletest-filter-unittest.py.

◆ testShardingWorksWithDeathTests()

def googletest-filter-unittest.GTestFilterUnitTest.testShardingWorksWithDeathTests (   self)
Tests integration with death tests and sharding.

Definition at line 617 of file googletest-filter-unittest.py.

◆ testShardStatusFileIsCreated()

def googletest-filter-unittest.GTestFilterUnitTest.testShardStatusFileIsCreated (   self)
Tests that the shard file is created if specified in the environment.

Definition at line 579 of file googletest-filter-unittest.py.

◆ testShardStatusFileIsCreatedWithListTests()

def googletest-filter-unittest.GTestFilterUnitTest.testShardStatusFileIsCreatedWithListTests (   self)
Tests that the shard file is created with the "list_tests" flag.

Definition at line 593 of file googletest-filter-unittest.py.

◆ testThreePatterns()

def googletest-filter-unittest.GTestFilterUnitTest.testThreePatterns (   self)
Tests filters that consist of three patterns.

Definition at line 488 of file googletest-filter-unittest.py.

◆ testTwoPatterns()

def googletest-filter-unittest.GTestFilterUnitTest.testTwoPatterns (   self)
Tests filters that consist of two patterns.

Definition at line 475 of file googletest-filter-unittest.py.

◆ testUniversalFilters()

def googletest-filter-unittest.GTestFilterUnitTest.testUniversalFilters (   self)
Tests filters that match everything.

Definition at line 398 of file googletest-filter-unittest.py.

◆ testWildcardInTestCaseName()

def googletest-filter-unittest.GTestFilterUnitTest.testWildcardInTestCaseName (   self)
Tests using wildcard in the test case name.

Definition at line 447 of file googletest-filter-unittest.py.

◆ testWildcardInTestName()

def googletest-filter-unittest.GTestFilterUnitTest.testWildcardInTestName (   self)
Tests using wildcard in the test name.

Definition at line 459 of file googletest-filter-unittest.py.


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


libaditof
Author(s):
autogenerated on Wed May 21 2025 02:07:10