diff options
author | Brad King <brad.king@kitware.com> | 2014-03-13 19:49:08 (GMT) |
---|---|---|
committer | Brad King <brad.king@kitware.com> | 2014-03-13 19:57:03 (GMT) |
commit | a25b809f2075828e5ae488f74d85f5a31940460a (patch) | |
tree | 6e5bd7afa074bf4e9f3350da27e0896604cd22e4 /Tests/RunCMake/find_dependency | |
parent | 9914e7cd95b29ee85653ab952a377f61dabd5190 (diff) | |
download | CMake-a25b809f2075828e5ae488f74d85f5a31940460a.zip CMake-a25b809f2075828e5ae488f74d85f5a31940460a.tar.gz CMake-a25b809f2075828e5ae488f74d85f5a31940460a.tar.bz2 |
Tests: Check find_dependency empty extra arguments
Add cases for empty arg 2 and arg 3.
Diffstat (limited to 'Tests/RunCMake/find_dependency')
7 files changed, 22 insertions, 0 deletions
diff --git a/Tests/RunCMake/find_dependency/RunCMakeTest.cmake b/Tests/RunCMake/find_dependency/RunCMakeTest.cmake index b85104a..9403136 100644 --- a/Tests/RunCMake/find_dependency/RunCMakeTest.cmake +++ b/Tests/RunCMake/find_dependency/RunCMakeTest.cmake @@ -1,5 +1,7 @@ include(RunCMake) run_cmake(EXACT-no-version) +run_cmake(empty-version) +run_cmake(empty-arg-3) run_cmake(invalid-arg-3) run_cmake(extra-args) diff --git a/Tests/RunCMake/find_dependency/empty-arg-3-result.txt b/Tests/RunCMake/find_dependency/empty-arg-3-result.txt new file mode 100644 index 0000000..d00491f --- /dev/null +++ b/Tests/RunCMake/find_dependency/empty-arg-3-result.txt @@ -0,0 +1 @@ +1 diff --git a/Tests/RunCMake/find_dependency/empty-arg-3-stderr.txt b/Tests/RunCMake/find_dependency/empty-arg-3-stderr.txt new file mode 100644 index 0000000..bf9b02b --- /dev/null +++ b/Tests/RunCMake/find_dependency/empty-arg-3-stderr.txt @@ -0,0 +1,5 @@ +CMake Error at .*Modules/CMakeFindDependencyMacro.cmake:[0-9]+ \(message\): + Invalid arguments to find_dependency +Call Stack \(most recent call first\): + empty-arg-3.cmake:4 \(find_dependency\) + CMakeLists.txt:4 \(include\) diff --git a/Tests/RunCMake/find_dependency/empty-arg-3.cmake b/Tests/RunCMake/find_dependency/empty-arg-3.cmake new file mode 100644 index 0000000..b08200a --- /dev/null +++ b/Tests/RunCMake/find_dependency/empty-arg-3.cmake @@ -0,0 +1,4 @@ + +include(CMakeFindDependencyMacro) + +find_dependency(Pack1 1.2 "") diff --git a/Tests/RunCMake/find_dependency/empty-version-result.txt b/Tests/RunCMake/find_dependency/empty-version-result.txt new file mode 100644 index 0000000..d00491f --- /dev/null +++ b/Tests/RunCMake/find_dependency/empty-version-result.txt @@ -0,0 +1 @@ +1 diff --git a/Tests/RunCMake/find_dependency/empty-version-stderr.txt b/Tests/RunCMake/find_dependency/empty-version-stderr.txt new file mode 100644 index 0000000..b5e9f46 --- /dev/null +++ b/Tests/RunCMake/find_dependency/empty-version-stderr.txt @@ -0,0 +1,5 @@ +CMake Error at .*/Modules/CMakeFindDependencyMacro.cmake:[0-9]+ \(message\): + Invalid arguments to find_dependency. VERSION is empty +Call Stack \(most recent call first\): + empty-version.cmake:4 \(find_dependency\) + CMakeLists.txt:4 \(include\) diff --git a/Tests/RunCMake/find_dependency/empty-version.cmake b/Tests/RunCMake/find_dependency/empty-version.cmake new file mode 100644 index 0000000..e6f17cd --- /dev/null +++ b/Tests/RunCMake/find_dependency/empty-version.cmake @@ -0,0 +1,4 @@ + +include(CMakeFindDependencyMacro) + +find_dependency(Pack1 "") |