From 379e5f93a9307eb77cf35052e83853939573ae44 Mon Sep 17 00:00:00 2001 From: Brad King Date: Fri, 26 Oct 2018 09:52:36 -0400 Subject: Tests: Add cases for -{C,D,U} without a source tree --- Tests/RunCMake/CommandLine/C-no-file-stderr.txt | 2 +- Tests/RunCMake/CommandLine/Cno-file-result.txt | 1 + Tests/RunCMake/CommandLine/Cno-file-stderr.txt | 3 +++ Tests/RunCMake/CommandLine/D-no-src-result.txt | 1 + Tests/RunCMake/CommandLine/D-no-src-stderr.txt | 2 ++ Tests/RunCMake/CommandLine/Dno-src-result.txt | 1 + Tests/RunCMake/CommandLine/Dno-src-stderr.txt | 2 ++ Tests/RunCMake/CommandLine/RunCMakeTest.cmake | 5 +++++ Tests/RunCMake/CommandLine/U-no-src-result.txt | 1 + Tests/RunCMake/CommandLine/U-no-src-stderr.txt | 2 ++ Tests/RunCMake/CommandLine/Uno-src-result.txt | 1 + Tests/RunCMake/CommandLine/Uno-src-stderr.txt | 2 ++ 12 files changed, 22 insertions(+), 1 deletion(-) create mode 100644 Tests/RunCMake/CommandLine/Cno-file-result.txt create mode 100644 Tests/RunCMake/CommandLine/Cno-file-stderr.txt create mode 100644 Tests/RunCMake/CommandLine/D-no-src-result.txt create mode 100644 Tests/RunCMake/CommandLine/D-no-src-stderr.txt create mode 100644 Tests/RunCMake/CommandLine/Dno-src-result.txt create mode 100644 Tests/RunCMake/CommandLine/Dno-src-stderr.txt create mode 100644 Tests/RunCMake/CommandLine/U-no-src-result.txt create mode 100644 Tests/RunCMake/CommandLine/U-no-src-stderr.txt create mode 100644 Tests/RunCMake/CommandLine/Uno-src-result.txt create mode 100644 Tests/RunCMake/CommandLine/Uno-src-stderr.txt diff --git a/Tests/RunCMake/CommandLine/C-no-file-stderr.txt b/Tests/RunCMake/CommandLine/C-no-file-stderr.txt index 5315f59..2a4ee64 100644 --- a/Tests/RunCMake/CommandLine/C-no-file-stderr.txt +++ b/Tests/RunCMake/CommandLine/C-no-file-stderr.txt @@ -1,3 +1,3 @@ ^CMake Error: Error processing file: nosuchcachefile.txt -CMake Error: The source directory ".*/Tests/RunCMake/CommandLine/C-no-file-build/nosuchcachefile.txt" does not exist. +CMake Error: The source directory ".*/Tests/RunCMake/CommandLine/C-no-file-build" does not appear to contain CMakeLists.txt. Specify --help for usage, or press the help button on the CMake GUI.$ diff --git a/Tests/RunCMake/CommandLine/Cno-file-result.txt b/Tests/RunCMake/CommandLine/Cno-file-result.txt new file mode 100644 index 0000000..d00491f --- /dev/null +++ b/Tests/RunCMake/CommandLine/Cno-file-result.txt @@ -0,0 +1 @@ +1 diff --git a/Tests/RunCMake/CommandLine/Cno-file-stderr.txt b/Tests/RunCMake/CommandLine/Cno-file-stderr.txt new file mode 100644 index 0000000..67a2032 --- /dev/null +++ b/Tests/RunCMake/CommandLine/Cno-file-stderr.txt @@ -0,0 +1,3 @@ +^CMake Error: Error processing file: nosuchcachefile.txt +CMake Error: The source directory ".*/Tests/RunCMake/CommandLine/Cno-file-build" does not appear to contain CMakeLists.txt. +Specify --help for usage, or press the help button on the CMake GUI.$ diff --git a/Tests/RunCMake/CommandLine/D-no-src-result.txt b/Tests/RunCMake/CommandLine/D-no-src-result.txt new file mode 100644 index 0000000..d00491f --- /dev/null +++ b/Tests/RunCMake/CommandLine/D-no-src-result.txt @@ -0,0 +1 @@ +1 diff --git a/Tests/RunCMake/CommandLine/D-no-src-stderr.txt b/Tests/RunCMake/CommandLine/D-no-src-stderr.txt new file mode 100644 index 0000000..b5ac69c --- /dev/null +++ b/Tests/RunCMake/CommandLine/D-no-src-stderr.txt @@ -0,0 +1,2 @@ +^CMake Error: The source directory ".*/Tests/RunCMake/CommandLine/D-no-src-build" does not appear to contain CMakeLists.txt. +Specify --help for usage, or press the help button on the CMake GUI.$ diff --git a/Tests/RunCMake/CommandLine/Dno-src-result.txt b/Tests/RunCMake/CommandLine/Dno-src-result.txt new file mode 100644 index 0000000..d00491f --- /dev/null +++ b/Tests/RunCMake/CommandLine/Dno-src-result.txt @@ -0,0 +1 @@ +1 diff --git a/Tests/RunCMake/CommandLine/Dno-src-stderr.txt b/Tests/RunCMake/CommandLine/Dno-src-stderr.txt new file mode 100644 index 0000000..402c714 --- /dev/null +++ b/Tests/RunCMake/CommandLine/Dno-src-stderr.txt @@ -0,0 +1,2 @@ +^CMake Error: The source directory ".*/Tests/RunCMake/CommandLine/Dno-src-build" does not appear to contain CMakeLists.txt. +Specify --help for usage, or press the help button on the CMake GUI.$ diff --git a/Tests/RunCMake/CommandLine/RunCMakeTest.cmake b/Tests/RunCMake/CommandLine/RunCMakeTest.cmake index 9859df1..b47abfb 100644 --- a/Tests/RunCMake/CommandLine/RunCMakeTest.cmake +++ b/Tests/RunCMake/CommandLine/RunCMakeTest.cmake @@ -6,10 +6,15 @@ run_cmake_command(NoArgs ${CMAKE_COMMAND}) run_cmake_command(Wizard ${CMAKE_COMMAND} -i) run_cmake_command(C-no-arg ${CMAKE_COMMAND} -C) run_cmake_command(C-no-file ${CMAKE_COMMAND} -C nosuchcachefile.txt) +run_cmake_command(Cno-file ${CMAKE_COMMAND} -Cnosuchcachefile.txt) run_cmake_command(cache-no-file ${CMAKE_COMMAND} nosuchsubdir/CMakeCache.txt) run_cmake_command(lists-no-file ${CMAKE_COMMAND} nosuchsubdir/CMakeLists.txt) run_cmake_command(D-no-arg ${CMAKE_COMMAND} -D) +run_cmake_command(D-no-src ${CMAKE_COMMAND} -D VAR=VALUE) +run_cmake_command(Dno-src ${CMAKE_COMMAND} -DVAR=VALUE) run_cmake_command(U-no-arg ${CMAKE_COMMAND} -U) +run_cmake_command(U-no-src ${CMAKE_COMMAND} -U VAR) +run_cmake_command(Uno-src ${CMAKE_COMMAND} -UVAR) run_cmake_command(E-no-arg ${CMAKE_COMMAND} -E) run_cmake_command(E_capabilities ${CMAKE_COMMAND} -E capabilities) run_cmake_command(E_capabilities-arg ${CMAKE_COMMAND} -E capabilities --extra-arg) diff --git a/Tests/RunCMake/CommandLine/U-no-src-result.txt b/Tests/RunCMake/CommandLine/U-no-src-result.txt new file mode 100644 index 0000000..d00491f --- /dev/null +++ b/Tests/RunCMake/CommandLine/U-no-src-result.txt @@ -0,0 +1 @@ +1 diff --git a/Tests/RunCMake/CommandLine/U-no-src-stderr.txt b/Tests/RunCMake/CommandLine/U-no-src-stderr.txt new file mode 100644 index 0000000..a3b4b12 --- /dev/null +++ b/Tests/RunCMake/CommandLine/U-no-src-stderr.txt @@ -0,0 +1,2 @@ +^CMake Error: The source directory ".*/Tests/RunCMake/CommandLine/U-no-src-build" does not appear to contain CMakeLists.txt. +Specify --help for usage, or press the help button on the CMake GUI.$ diff --git a/Tests/RunCMake/CommandLine/Uno-src-result.txt b/Tests/RunCMake/CommandLine/Uno-src-result.txt new file mode 100644 index 0000000..d00491f --- /dev/null +++ b/Tests/RunCMake/CommandLine/Uno-src-result.txt @@ -0,0 +1 @@ +1 diff --git a/Tests/RunCMake/CommandLine/Uno-src-stderr.txt b/Tests/RunCMake/CommandLine/Uno-src-stderr.txt new file mode 100644 index 0000000..baa8d63 --- /dev/null +++ b/Tests/RunCMake/CommandLine/Uno-src-stderr.txt @@ -0,0 +1,2 @@ +^CMake Error: The source directory ".*/Tests/RunCMake/CommandLine/Uno-src-build" does not appear to contain CMakeLists.txt. +Specify --help for usage, or press the help button on the CMake GUI.$ -- cgit v0.12