gtest_list_output_unittest.py (googletest-release-1.11.0) | : | gtest_list_output_unittest.py (googletest-release-1.12.0) | ||
---|---|---|---|---|
skipping to change at line 43 | skipping to change at line 43 | |||
A user can ask Google Test to list all tests by specifying the | A user can ask Google Test to list all tests by specifying the | |||
--gtest_list_tests flag. If output is requested, via --gtest_output=xml | --gtest_list_tests flag. If output is requested, via --gtest_output=xml | |||
or --gtest_output=json, the tests are listed, with extra information in the | or --gtest_output=json, the tests are listed, with extra information in the | |||
output file. | output file. | |||
This script tests such functionality by invoking gtest_list_output_unittest_ | This script tests such functionality by invoking gtest_list_output_unittest_ | |||
(a program written with Google Test) the command line flags. | (a program written with Google Test) the command line flags. | |||
""" | """ | |||
import os | import os | |||
import re | import re | |||
import gtest_test_utils | from googletest.test import gtest_test_utils | |||
GTEST_LIST_TESTS_FLAG = '--gtest_list_tests' | GTEST_LIST_TESTS_FLAG = '--gtest_list_tests' | |||
GTEST_OUTPUT_FLAG = '--gtest_output' | GTEST_OUTPUT_FLAG = '--gtest_output' | |||
EXPECTED_XML = """<\?xml version="1.0" encoding="UTF-8"\?> | EXPECTED_XML = """<\?xml version="1.0" encoding="UTF-8"\?> | |||
<testsuites tests="16" name="AllTests"> | <testsuites tests="16" name="AllTests"> | |||
<testsuite name="FooTest" tests="2"> | <testsuite name="FooTest" tests="2"> | |||
<testcase name="Test1" file=".*gtest_list_output_unittest_.cc" line="43" /> | <testcase name="Test1" file=".*gtest_list_output_unittest_.cc" line="43" /> | |||
<testcase name="Test2" file=".*gtest_list_output_unittest_.cc" line="45" /> | <testcase name="Test2" file=".*gtest_list_output_unittest_.cc" line="45" /> | |||
</testsuite> | </testsuite> | |||
End of changes. 1 change blocks. | ||||
1 lines changed or deleted | 1 lines changed or added |