summaryrefslogtreecommitdiffstats
path: root/Tests/RunCMake/CXXModules/NinjaDependInfoFileSet-check.cmake
diff options
context:
space:
mode:
Diffstat (limited to 'Tests/RunCMake/CXXModules/NinjaDependInfoFileSet-check.cmake')
-rw-r--r--Tests/RunCMake/CXXModules/NinjaDependInfoFileSet-check.cmake15
1 files changed, 10 insertions, 5 deletions
diff --git a/Tests/RunCMake/CXXModules/NinjaDependInfoFileSet-check.cmake b/Tests/RunCMake/CXXModules/NinjaDependInfoFileSet-check.cmake
index b9a1315..4eaa891 100644
--- a/Tests/RunCMake/CXXModules/NinjaDependInfoFileSet-check.cmake
+++ b/Tests/RunCMake/CXXModules/NinjaDependInfoFileSet-check.cmake
@@ -2,19 +2,19 @@ include("${CMAKE_CURRENT_LIST_DIR}/check-json.cmake")
if (RunCMake_GENERATOR_IS_MULTI_CONFIG)
set(have_file 0)
- foreach (config IN ITEMS Release Debug RelWithDebInfo MinSizeRel)
- if (NOT EXISTS "${RunCMake_TEST_BINARY_DIR}/CMakeFiles/ninja-file-sets-public.dir/${config}/CXXDependInfo.json")
+ foreach (CXXModules_config IN ITEMS Release Debug RelWithDebInfo MinSizeRel)
+ if (NOT EXISTS "${RunCMake_TEST_BINARY_DIR}/CMakeFiles/ninja-file-sets-public.dir/${CXXModules_config}/CXXDependInfo.json")
continue ()
endif ()
set(have_file 1)
- set(CMAKE_BUILD_TYPE "${config}")
+ set(CMAKE_BUILD_TYPE "${CXXModules_config}")
- file(READ "${RunCMake_TEST_BINARY_DIR}/CMakeFiles/ninja-file-sets-public.dir/${config}/CXXDependInfo.json" actual_contents)
+ file(READ "${RunCMake_TEST_BINARY_DIR}/CMakeFiles/ninja-file-sets-public.dir/${CXXModules_config}/CXXDependInfo.json" actual_contents)
file(READ "${CMAKE_CURRENT_LIST_DIR}/expect/NinjaDependInfoFileSet-public.json" expect_contents)
check_json("${actual_contents}" "${expect_contents}")
- file(READ "${RunCMake_TEST_BINARY_DIR}/CMakeFiles/ninja-file-sets-private.dir/${config}/CXXDependInfo.json" actual_contents)
+ file(READ "${RunCMake_TEST_BINARY_DIR}/CMakeFiles/ninja-file-sets-private.dir/${CXXModules_config}/CXXDependInfo.json" actual_contents)
file(READ "${CMAKE_CURRENT_LIST_DIR}/expect/NinjaDependInfoFileSet-private.json" expect_contents)
check_json("${actual_contents}" "${expect_contents}")
endforeach ()
@@ -24,6 +24,9 @@ if (RunCMake_GENERATOR_IS_MULTI_CONFIG)
"No recognized build configurations found.")
endif ()
else ()
+ set(CXXModules_config "${CXXModules_default_build_type}")
+ set(CMAKE_BUILD_TYPE "${CXXModules_default_build_type}")
+
file(READ "${RunCMake_TEST_BINARY_DIR}/CMakeFiles/ninja-file-sets-public.dir/CXXDependInfo.json" actual_contents)
file(READ "${CMAKE_CURRENT_LIST_DIR}/expect/NinjaDependInfoFileSet-public.json" expect_contents)
check_json("${actual_contents}" "${expect_contents}")
@@ -32,3 +35,5 @@ else ()
file(READ "${CMAKE_CURRENT_LIST_DIR}/expect/NinjaDependInfoFileSet-private.json" expect_contents)
check_json("${actual_contents}" "${expect_contents}")
endif ()
+
+string(REPLACE ";" "\n " RunCMake_TEST_FAILED "${RunCMake_TEST_FAILED}")