summaryrefslogtreecommitdiffstats
path: root/Tests
diff options
context:
space:
mode:
authorAlexander Krabler <code@a.krabler.eu>2023-12-16 14:51:25 (GMT)
committerBrad King <brad.king@kitware.com>2023-12-18 14:03:51 (GMT)
commit2ea216a6bb46c8421677fd34ba6d1cc2999063be (patch)
tree51db97b82950293e94956897cb90d0dda2dc6371 /Tests
parentba41ca758af655d320d9bc2ca52d4c15c6f25b50 (diff)
downloadCMake-2ea216a6bb46c8421677fd34ba6d1cc2999063be.zip
CMake-2ea216a6bb46c8421677fd34ba6d1cc2999063be.tar.gz
CMake-2ea216a6bb46c8421677fd34ba6d1cc2999063be.tar.bz2
GoogleTest: Add working directory to gtest_discover_tests error message
If the working directory didn't exist, the old message just says: Error running test executable. Path: '<Path to test executable>' Result: No such file or directory Output: This leads the user to the conclusion that the test executable doesn't exist, which isn't true. Make the true cause visible by reporting the working directory in the error message.
Diffstat (limited to 'Tests')
-rw-r--r--Tests/RunCMake/GoogleTest/GoogleTest-discovery-POST_BUILD-timeout-build-stdout.txt1
-rw-r--r--Tests/RunCMake/GoogleTest/GoogleTest-discovery-PRE_TEST-timeout-test-stderr.txt1
2 files changed, 2 insertions, 0 deletions
diff --git a/Tests/RunCMake/GoogleTest/GoogleTest-discovery-POST_BUILD-timeout-build-stdout.txt b/Tests/RunCMake/GoogleTest/GoogleTest-discovery-POST_BUILD-timeout-build-stdout.txt
index 3a6572c..84bbe9f 100644
--- a/Tests/RunCMake/GoogleTest/GoogleTest-discovery-POST_BUILD-timeout-build-stdout.txt
+++ b/Tests/RunCMake/GoogleTest/GoogleTest-discovery-POST_BUILD-timeout-build-stdout.txt
@@ -2,6 +2,7 @@
( *|[0-9]+>) Error running test executable.
?( *|[0-9]+>)
( *|[0-9]+>) Path: '.*discovery_timeout_test(\.exe)?'
+( *|[0-9]+>) Working directory: '[^']*/Tests/RunCMake/GoogleTest/GoogleTest-discovery-timeout'
( *|[0-9]+>) Result: Process terminated due to timeout
( *|[0-9]+>) Output:
( *|[0-9]+>) +
diff --git a/Tests/RunCMake/GoogleTest/GoogleTest-discovery-PRE_TEST-timeout-test-stderr.txt b/Tests/RunCMake/GoogleTest/GoogleTest-discovery-PRE_TEST-timeout-test-stderr.txt
index 75afe4a..03d73ee 100644
--- a/Tests/RunCMake/GoogleTest/GoogleTest-discovery-PRE_TEST-timeout-test-stderr.txt
+++ b/Tests/RunCMake/GoogleTest/GoogleTest-discovery-PRE_TEST-timeout-test-stderr.txt
@@ -2,6 +2,7 @@ CMake Error at .*GoogleTestAddTests.cmake:[0-9]+ \(message\):
[ \t]*Error running test executable.
+
[ \t]*Path: '.*discovery_timeout_test(\.exe)?'
+[ \t]*Working directory: '[^']*/Tests/RunCMake/GoogleTest/GoogleTest-discovery-timeout'
[ \t]*Result: Process terminated due to timeout
[ \t]*Output:
[ \t]*timeout.