Lab_1 0.1.1
Matrix Library
Loading...
Searching...
No Matches
gtest_help_test Namespace Reference

Classes

class  GTestHelpTest
 

Functions

 RunWithFlag (flag)
 

Variables

str IS_LINUX = 'Linux'
 
str IS_GNUHURD = 'GNU'
 
str IS_GNUKFREEBSD = 'GNU/kFreeBSD'
 
str IS_OPENBSD = 'OpenBSD'
 
str IS_WINDOWS = 'nt'
 
 PROGRAM_PATH = gtest_test_utils.GetTestExecutablePath('gtest_help_test_')
 
str FLAG_PREFIX = '--gtest_'
 
str DEATH_TEST_STYLE_FLAG = FLAG_PREFIX + 'death_test_style'
 
str STREAM_RESULT_TO_FLAG = FLAG_PREFIX + 'stream_result_to'
 
str UNKNOWN_GTEST_PREFIXED_FLAG = FLAG_PREFIX + 'unknown_flag_for_testing'
 
str LIST_TESTS_FLAG = FLAG_PREFIX + 'list_tests'
 
str INTERNAL_FLAG_FOR_TESTING = FLAG_PREFIX + 'internal_flag_for_testing'
 
str SUPPORTS_DEATH_TESTS
 
str HAS_ABSL_FLAGS = '--has_absl_flags' in sys.argv
 
 HELP_REGEX
 

Detailed Description

Tests the --help flag of Google C++ Testing and Mocking Framework.

SYNOPSIS
       gtest_help_test.py --build_dir=BUILD/DIR
         # where BUILD/DIR contains the built gtest_help_test_ file.
       gtest_help_test.py

Function Documentation

◆ RunWithFlag()

gtest_help_test.RunWithFlag ( flag)
Runs gtest_help_test_ with the given flag.

Returns:
  the exit code and the text output as a tuple.
Args:
  flag: the command-line flag to pass to gtest_help_test_, or None.

Variable Documentation

◆ HELP_REGEX

gtest_help_test.HELP_REGEX
Initial value:
1= re.compile(
2 FLAG_PREFIX + r'list_tests.*' +
3 FLAG_PREFIX + r'filter=.*' +
4 FLAG_PREFIX + r'also_run_disabled_tests.*' +
5 FLAG_PREFIX + r'repeat=.*' +
6 FLAG_PREFIX + r'shuffle.*' +
7 FLAG_PREFIX + r'random_seed=.*' +
8 FLAG_PREFIX + r'color=.*' +
9 FLAG_PREFIX + r'brief.*' +
10 FLAG_PREFIX + r'print_time.*' +
11 FLAG_PREFIX + r'output=.*' +
12 FLAG_PREFIX + r'break_on_failure.*' +
13 FLAG_PREFIX + r'throw_on_failure.*' +
14 FLAG_PREFIX + r'catch_exceptions=0.*',
15 re.DOTALL)

◆ SUPPORTS_DEATH_TESTS

str gtest_help_test.SUPPORTS_DEATH_TESTS
Initial value:
1= "DeathTest" in gtest_test_utils.Subprocess(
2 [PROGRAM_PATH, LIST_TESTS_FLAG]).output
Definition gtest_test_utils.py:196