This adds fine grained execution of Google Test test programs
First, the Google Test test is executed with `--gtest_list_tests`. Next, based on the output from `--gtest_list_tests`, the testcases are run individually. The output from each unique testcase is based on the standard output it provides, per the test output protocol defined in the GoogleTest docs on github [1], [2], and instrumented via various demo programs I created, which can be found on GitHub [here](https://github.com/ngie-eign/scratch/tree/master/programming/c%2B%2B/gtest).
This support is a very rough cut to provide an initial working integration effort. There're additional improvements that can be made by leveraging either the JSON or XML structured output format, instead of scraping standard output using beginning and ending sentinels to search for regular expressions. In order to do that though without reinventing the wheel, Kyua would need to rely on an external JSON or XML library.
This test interface supports fine grained execution of test programs like the ATF test interface, but matches the plain/TAP interfaces by instead supporting metadata passing via `TEST_ENV` prefixed environment variables.
This support adds additional tests for verifying pass, fail, skip, and disabled result determination, using mock output and a mock test program (`engine/googletest_helpers`), for parity with other test formats (ATF, plain, TAP).
1. https://github.com/google/googletest/blob/master/googletest/docs/primer.md 2. https://github.com/google/googletest/blob/master/googletest/docs/advanced.md
Signed-off-by: Enji Cooper <yaneu...@gmail.com>
|