mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2024-11-23 11:13:28 +01:00
5f81d65876
Summary: Upstream googletest prints "Running main() from gtest_main.cc" to stdout prior to running tests. LLVM removed that print statement in r61540. If a user were to use lit to run tests that use upstream googletest, however, lit reports "Running main()" as an invalid test name. To avoid such a failure, add an extra conditional to `formats/googletest.py`. Also add tests to demonstrate the modified behavior. Reviewers: abdulras, ddunbar Subscribers: ddunbar, llvm-commits, kastiglione Differential Revision: http://reviews.llvm.org/D18606 llvm-svn: 265034
21 lines
882 B
Python
21 lines
882 B
Python
# Check the various features of the GoogleTest format.
|
|
#
|
|
# RUN: not %{lit} -j 1 -v %{inputs}/googletest-upstream-format > %t.out
|
|
# RUN: FileCheck < %t.out %s
|
|
#
|
|
# END.
|
|
|
|
# CHECK: -- Testing:
|
|
# CHECK: PASS: googletest-upstream-format :: DummySubDir/OneTest/FirstTest.subTestA
|
|
# CHECK: FAIL: googletest-upstream-format :: DummySubDir/OneTest/FirstTest.subTestB
|
|
# CHECK-NEXT: *** TEST 'googletest-upstream-format :: DummySubDir/OneTest/FirstTest.subTestB' FAILED ***
|
|
# CHECK-NEXT: Running main() from gtest_main.cc
|
|
# CHECK-NEXT: I am subTest B, I FAIL
|
|
# CHECK-NEXT: And I have two lines of output
|
|
# CHECK: ***
|
|
# CHECK: PASS: googletest-upstream-format :: DummySubDir/OneTest/ParameterizedTest/0.subTest
|
|
# CHECK: PASS: googletest-upstream-format :: DummySubDir/OneTest/ParameterizedTest/1.subTest
|
|
# CHECK: Failing Tests (1)
|
|
# CHECK: Expected Passes : 3
|
|
# CHECK: Unexpected Failures: 1
|