summaryrefslogtreecommitdiff
path: root/Tests/RunCMake/ctest_build/ParallelLevel-check.cmake
diff options
context:
space:
mode:
Diffstat (limited to 'Tests/RunCMake/ctest_build/ParallelLevel-check.cmake')
-rw-r--r--Tests/RunCMake/ctest_build/ParallelLevel-check.cmake11
1 files changed, 11 insertions, 0 deletions
diff --git a/Tests/RunCMake/ctest_build/ParallelLevel-check.cmake b/Tests/RunCMake/ctest_build/ParallelLevel-check.cmake
new file mode 100644
index 000000000..f45d2a29f
--- /dev/null
+++ b/Tests/RunCMake/ctest_build/ParallelLevel-check.cmake
@@ -0,0 +1,11 @@
+file(GLOB build_xml_file "${RunCMake_TEST_BINARY_DIR}/Testing/*/Build.xml")
+if(build_xml_file)
+ file(STRINGS "${build_xml_file}" build_cmd LIMIT_COUNT 1 REGEX "<BuildCommand>")
+ if(NOT build_cmd MATCHES [[ --parallel "1"]])
+ set(RunCMake_TEST_FAILED
+ "Build.xml does not have expected build command with --parallel flag"
+ )
+ endif()
+else()
+ set(RunCMake_TEST_FAILED "Build.xml not found")
+endif()