|
cMHN 1.2
C++ library for learning MHNs with pRC
|
Classes | |
| class | GTestOutputTest |
Functions | |
| ToUnixLineEnding (s) | |
| RemoveLocations (test_output) | |
| RemoveStackTraceDetails (output) | |
| RemoveStackTraces (output) | |
| RemoveTime (output) | |
| RemoveTypeInfoDetails (test_output) | |
| NormalizeToCurrentPlatform (test_output) | |
| RemoveTestCounts (output) | |
| RemoveMatchingTests (test_output, pattern) | |
| NormalizeOutput (output) | |
| GetShellCommandOutput (env_cmd) | |
| GetCommandOutput (env_cmd) | |
| GetOutputOfAllCommands () | |
| googletest-output-test.GetCommandOutput | ( | env_cmd | ) |
Runs a command and returns output with all file location info stripped off.
Args:
env_cmd: The shell command. A 2-tuple where element 0 is a dict of extra
environment variables to set, and element 1 is a string with the command
and any flags.
Returns:
A string with the command's combined standard and diagnostic output. File
location info is stripped.
| googletest-output-test.GetOutputOfAllCommands | ( | ) |
Returns concatenated output from several representative commands.
| googletest-output-test.GetShellCommandOutput | ( | env_cmd | ) |
Runs a command in a sub-process, and returns its output in a string.
Args:
env_cmd: The shell command. A 2-tuple where element 0 is a dict of extra
environment variables to set, and element 1 is a string with the command
and any flags.
Returns:
A string with the command's combined standard and diagnostic output.
| googletest-output-test.NormalizeOutput | ( | output | ) |
Normalizes output (the output of googletest-output-test_.exe).
| googletest-output-test.NormalizeToCurrentPlatform | ( | test_output | ) |
Normalizes platform specific output details for easier comparison.
| googletest-output-test.RemoveLocations | ( | test_output | ) |
Removes all file location info from a Google Test program's output.
Args:
test_output: the output of a Google Test program.
Returns:
output with all file location info (in the form of
'DIRECTORY/FILE_NAME:LINE_NUMBER: 'or
'DIRECTORY\\FILE_NAME(LINE_NUMBER): ') replaced by
'FILE_NAME:#: '.
| googletest-output-test.RemoveMatchingTests | ( | test_output, | |
| pattern ) |
Removes output of specified tests from a Google Test program's output.
This function strips not only the beginning and the end of a test but also
all output in between.
Args:
test_output: A string containing the test output.
pattern: A regex string that matches names of test cases or tests
to remove.
Returns:
Contents of test_output with tests whose names match pattern removed.
| googletest-output-test.RemoveStackTraceDetails | ( | output | ) |
Removes all stack traces from a Google Test program's output.
| googletest-output-test.RemoveStackTraces | ( | output | ) |
Removes all traces of stack traces from a Google Test program's output.
| googletest-output-test.RemoveTestCounts | ( | output | ) |
Removes test counts from a Google Test program's output.
| googletest-output-test.RemoveTime | ( | output | ) |
Removes all time information from a Google Test program's output.
| googletest-output-test.RemoveTypeInfoDetails | ( | test_output | ) |
Removes compiler-specific type info from Google Test program's output.
Args:
test_output: the output of a Google Test program.
Returns:
output with type information normalized to canonical form.
| googletest-output-test.ToUnixLineEnding | ( | s | ) |
Changes all Windows/Mac line endings in s to UNIX line endings.
| tuple googletest-output-test.CAN_GENERATE_GOLDEN_FILE |
| str googletest-output-test.CATCH_EXCEPTIONS_ENV_VAR_NAME = 'GTEST_CATCH_EXCEPTIONS' |
| tuple googletest-output-test.COMMAND_LIST_TESTS = ({}, [PROGRAM_PATH, '--gtest_list_tests']) |
| tuple googletest-output-test.COMMAND_WITH_COLOR = ({}, [PROGRAM_PATH, '--gtest_color=yes']) |
| tuple googletest-output-test.COMMAND_WITH_DISABLED |
| tuple googletest-output-test.COMMAND_WITH_SHARDING |
| tuple googletest-output-test.COMMAND_WITH_TIME |
| str googletest-output-test.GENGOLDEN_FLAG = '--gengolden' |
| googletest-output-test.golden_file = open(GOLDEN_PATH, 'wb') |
| googletest-output-test.GOLDEN_PATH = os.path.join(gtest_test_utils.GetSourceDir(), GOLDEN_NAME) |
| str googletest-output-test.IS_LINUX = 'Linux' |
| str googletest-output-test.IS_WINDOWS = 'nt' |
| str googletest-output-test.message |
| str googletest-output-test.NO_STACKTRACE_SUPPORT_FLAG = '--no_stacktrace_support' |
| googletest-output-test.output = GetOutputOfAllCommands() |
| googletest-output-test.PROGRAM_PATH = gtest_test_utils.GetTestExecutablePath('googletest-output-test_') |
| str googletest-output-test.SUPPORTS_STACK_TRACES = NO_STACKTRACE_SUPPORT_FLAG not in sys.argv |
| googletest-output-test.test_list = GetShellCommandOutput(COMMAND_LIST_TESTS) |