summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2019-06-04 12:24:18 (GMT)
committerKitware Robot <kwrobot@kitware.com>2019-06-04 12:24:29 (GMT)
commit7561fcda0918abf71b7fb0cfe67dd70fafe577ae (patch)
tree3956cf2838f3b38963a54137dc8fedb5592ab264
parent99496f57769a45fb664f6865bd6935d37fe45467 (diff)
parentf263650f95bdf87e2c50ada4a28d4fb729ac6f1c (diff)
downloadCMake-7561fcda0918abf71b7fb0cfe67dd70fafe577ae.zip
CMake-7561fcda0918abf71b7fb0cfe67dd70fafe577ae.tar.gz
CMake-7561fcda0918abf71b7fb0cfe67dd70fafe577ae.tar.bz2
Merge topic 'test-explicit-dirs'
f263650f95 Tests: Fix RunCMake.CommandLine test to use generator in no-S-B case Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !3414
-rw-r--r--Tests/RunCMake/CommandLine/RunCMakeTest.cmake10
1 files changed, 6 insertions, 4 deletions
diff --git a/Tests/RunCMake/CommandLine/RunCMakeTest.cmake b/Tests/RunCMake/CommandLine/RunCMakeTest.cmake
index cee996c..7798b62 100644
--- a/Tests/RunCMake/CommandLine/RunCMakeTest.cmake
+++ b/Tests/RunCMake/CommandLine/RunCMakeTest.cmake
@@ -68,6 +68,9 @@ run_cmake_command(cache-empty-entry
${CMAKE_COMMAND} --build ${RunCMake_SOURCE_DIR}/cache-empty-entry/)
function(run_ExplicitDirs)
+ set(RunCMake_TEST_NO_CLEAN 1)
+ set(RunCMake_TEST_NO_SOURCE_DIR 1)
+
set(source_dir ${RunCMake_BINARY_DIR}/ExplicitDirsMissing)
file(REMOVE_RECURSE "${source_dir}")
@@ -76,16 +79,15 @@ function(run_ExplicitDirs)
cmake_minimum_required(VERSION 3.13)
project(ExplicitDirsMissing LANGUAGES NONE)
]=])
- run_cmake_command(no-S-B ${CMAKE_COMMAND} -E chdir ${source_dir}
- ${CMAKE_COMMAND} -DFOO=BAR)
+ set(RunCMake_TEST_SOURCE_DIR "${source_dir}")
+ set(RunCMake_TEST_BINARY_DIR "${source_dir}")
+ run_cmake_with_options(no-S-B -DFOO=BAR)
set(source_dir ${RunCMake_SOURCE_DIR}/ExplicitDirs)
set(binary_dir ${RunCMake_BINARY_DIR}/ExplicitDirs-build)
set(RunCMake_TEST_SOURCE_DIR "${source_dir}")
set(RunCMake_TEST_BINARY_DIR "${binary_dir}")
- set(RunCMake_TEST_NO_CLEAN 1)
- set(RunCMake_TEST_NO_SOURCE_DIR 1)
file(REMOVE_RECURSE "${binary_dir}")
run_cmake_with_options(S-arg -S ${source_dir} ${binary_dir})