Analysis Software
Documentation for sPHENIX simulation software
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
gtest_shuffle_test Namespace Reference

Classes

class  GTestShuffleUnitTest
 

Functions

def AlsoRunDisabledTestsFlag
 
def FilterFlag
 
def RepeatFlag
 
def ShuffleFlag
 
def RandomSeedFlag
 
def RunAndReturnOutput
 
def GetTestsForAllIterations
 
def GetTestCases
 
def CalculateTestLists
 

Variables

string __author__ 'wan@google.com (Zhanyong Wan)'
 
tuple COMMAND gtest_test_utils.GetTestExecutablePath('gtest_shuffle_test_')
 
string TOTAL_SHARDS_ENV_VAR 'GTEST_TOTAL_SHARDS'
 
string SHARD_INDEX_ENV_VAR 'GTEST_SHARD_INDEX'
 
string TEST_FILTER 'A*.A:A*.B:C*'
 
list ALL_TESTS []
 
list ACTIVE_TESTS []
 
list FILTERED_TESTS []
 
list SHARDED_TESTS []
 
list SHUFFLED_ALL_TESTS []
 
list SHUFFLED_ACTIVE_TESTS []
 
list SHUFFLED_FILTERED_TESTS []
 
list SHUFFLED_SHARDED_TESTS []
 

Function Documentation

def gtest_shuffle_test.AlsoRunDisabledTestsFlag ( )

Definition at line 58 of file gtest_shuffle_test.py.

View newest version in sPHENIX GitHub at line 58 of file gtest_shuffle_test.py

Referenced by CalculateTestLists().

+ Here is the caller graph for this function:

def gtest_shuffle_test.CalculateTestLists ( )
Calculates the list of tests run under different flags.

Definition at line 130 of file gtest_shuffle_test.py.

View newest version in sPHENIX GitHub at line 130 of file gtest_shuffle_test.py

References AlsoRunDisabledTestsFlag(), FilterFlag(), GetTestsForAllIterations(), RandomSeedFlag(), and ShuffleFlag().

Referenced by gtest_shuffle_test.GTestShuffleUnitTest.setUp().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

def gtest_shuffle_test.FilterFlag (   test_filter)

Definition at line 62 of file gtest_shuffle_test.py.

View newest version in sPHENIX GitHub at line 62 of file gtest_shuffle_test.py

Referenced by CalculateTestLists().

+ Here is the caller graph for this function:

def gtest_shuffle_test.GetTestCases (   tests)
Returns a list of test cases in the given full test names.

Args:
  tests: a list of full test names

Returns:
  A list of test cases from 'tests', in their original order.
  Consecutive duplicates are removed.

Definition at line 110 of file gtest_shuffle_test.py.

View newest version in sPHENIX GitHub at line 110 of file gtest_shuffle_test.py

Referenced by gtest_shuffle_test.GTestShuffleUnitTest.testShuffleChangesTestCaseOrder().

+ Here is the caller graph for this function:

def gtest_shuffle_test.GetTestsForAllIterations (   extra_env,
  args 
)
Runs the test program and returns a list of test lists.

Args:
  extra_env: a map from environment variables to their values
  args: command line flags to pass to gtest_shuffle_test_

Returns:
  A list where the i-th element is the list of tests run in the i-th
  test iteration.

Definition at line 87 of file gtest_shuffle_test.py.

View newest version in sPHENIX GitHub at line 87 of file gtest_shuffle_test.py

References RunAndReturnOutput().

Referenced by CalculateTestLists(), gtest_shuffle_test.GTestShuffleUnitTest.testShuffleGeneratesNewOrderInEachIteration(), gtest_shuffle_test.GTestShuffleUnitTest.testShuffleRestoresOrderAfterEachIteration(), and gtest_shuffle_test.GTestShuffleUnitTest.testShuffleShardedTestsPreservesPartition().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

def gtest_shuffle_test.RandomSeedFlag (   n)

Definition at line 74 of file gtest_shuffle_test.py.

View newest version in sPHENIX GitHub at line 74 of file gtest_shuffle_test.py

Referenced by CalculateTestLists(), gtest_shuffle_test.GTestShuffleUnitTest.testShuffleGeneratesNewOrderInEachIteration(), gtest_shuffle_test.GTestShuffleUnitTest.testShuffleRestoresOrderAfterEachIteration(), and gtest_shuffle_test.GTestShuffleUnitTest.testShuffleShardedTestsPreservesPartition().

+ Here is the caller graph for this function:

def gtest_shuffle_test.RepeatFlag (   n)

Definition at line 66 of file gtest_shuffle_test.py.

View newest version in sPHENIX GitHub at line 66 of file gtest_shuffle_test.py

Referenced by gtest_shuffle_test.GTestShuffleUnitTest.testShuffleGeneratesNewOrderInEachIteration(), and gtest_shuffle_test.GTestShuffleUnitTest.testShuffleRestoresOrderAfterEachIteration().

+ Here is the caller graph for this function:

def gtest_shuffle_test.RunAndReturnOutput (   extra_env,
  args 
)
Runs the test program and returns its output.

Definition at line 78 of file gtest_shuffle_test.py.

View newest version in sPHENIX GitHub at line 78 of file gtest_shuffle_test.py

Referenced by GetTestsForAllIterations().

+ Here is the caller graph for this function:

def gtest_shuffle_test.ShuffleFlag ( )

Definition at line 70 of file gtest_shuffle_test.py.

View newest version in sPHENIX GitHub at line 70 of file gtest_shuffle_test.py

Referenced by CalculateTestLists(), gtest_shuffle_test.GTestShuffleUnitTest.testShuffleGeneratesNewOrderInEachIteration(), gtest_shuffle_test.GTestShuffleUnitTest.testShuffleRestoresOrderAfterEachIteration(), and gtest_shuffle_test.GTestShuffleUnitTest.testShuffleShardedTestsPreservesPartition().

+ Here is the caller graph for this function:

Variable Documentation

string gtest_shuffle_test.__author__ 'wan@google.com (Zhanyong Wan)'

Definition at line 33 of file gtest_shuffle_test.py.

View newest version in sPHENIX GitHub at line 33 of file gtest_shuffle_test.py

list gtest_shuffle_test.ACTIVE_TESTS []

Definition at line 48 of file gtest_shuffle_test.py.

View newest version in sPHENIX GitHub at line 48 of file gtest_shuffle_test.py

list gtest_shuffle_test.ALL_TESTS []

Definition at line 47 of file gtest_shuffle_test.py.

View newest version in sPHENIX GitHub at line 47 of file gtest_shuffle_test.py

tuple gtest_shuffle_test.COMMAND gtest_test_utils.GetTestExecutablePath('gtest_shuffle_test_')

Definition at line 39 of file gtest_shuffle_test.py.

View newest version in sPHENIX GitHub at line 39 of file gtest_shuffle_test.py

list gtest_shuffle_test.FILTERED_TESTS []

Definition at line 49 of file gtest_shuffle_test.py.

View newest version in sPHENIX GitHub at line 49 of file gtest_shuffle_test.py

string gtest_shuffle_test.SHARD_INDEX_ENV_VAR 'GTEST_SHARD_INDEX'

Definition at line 43 of file gtest_shuffle_test.py.

View newest version in sPHENIX GitHub at line 43 of file gtest_shuffle_test.py

list gtest_shuffle_test.SHARDED_TESTS []

Definition at line 50 of file gtest_shuffle_test.py.

View newest version in sPHENIX GitHub at line 50 of file gtest_shuffle_test.py

list gtest_shuffle_test.SHUFFLED_ACTIVE_TESTS []

Definition at line 53 of file gtest_shuffle_test.py.

View newest version in sPHENIX GitHub at line 53 of file gtest_shuffle_test.py

list gtest_shuffle_test.SHUFFLED_ALL_TESTS []

Definition at line 52 of file gtest_shuffle_test.py.

View newest version in sPHENIX GitHub at line 52 of file gtest_shuffle_test.py

list gtest_shuffle_test.SHUFFLED_FILTERED_TESTS []

Definition at line 54 of file gtest_shuffle_test.py.

View newest version in sPHENIX GitHub at line 54 of file gtest_shuffle_test.py

list gtest_shuffle_test.SHUFFLED_SHARDED_TESTS []

Definition at line 55 of file gtest_shuffle_test.py.

View newest version in sPHENIX GitHub at line 55 of file gtest_shuffle_test.py

string gtest_shuffle_test.TEST_FILTER 'A*.A:A*.B:C*'

Definition at line 45 of file gtest_shuffle_test.py.

View newest version in sPHENIX GitHub at line 45 of file gtest_shuffle_test.py

string gtest_shuffle_test.TOTAL_SHARDS_ENV_VAR 'GTEST_TOTAL_SHARDS'

Definition at line 42 of file gtest_shuffle_test.py.

View newest version in sPHENIX GitHub at line 42 of file gtest_shuffle_test.py