Commit 220c5dc4 authored by Ben Boeckel's avatar Ben Boeckel

Add test that CMake errors with empty libs

When the library language cannot be determined, make sure CMake errors,
not segfaults (bug #11230)
parent 4e137de7
......@@ -153,6 +153,9 @@ IF(BUILD_TESTING)
ADD_TEST_MACRO(ExportImport ExportImport)
ADD_TEST_MACRO(Unset Unset)
ADD_TEST_MACRO(PolicyScope PolicyScope)
ADD_TEST_MACRO(EmptyLibrary EmptyLibrary)
SET_TESTS_PROPERTIES(EmptyLibrary PROPERTIES
PASS_REGULAR_EXPRESSION "CMake Error: Cannot determine link language for target \"test\"")
ADD_TEST_MACRO(CrossCompile CrossCompile)
SET_TESTS_PROPERTIES(CrossCompile PROPERTIES
PASS_REGULAR_EXPRESSION "TRY_RUN.. invoked in cross-compiling mode")
......
cmake_minimum_required(VERSION 2.6)
project(TestEmptyLibrary)
add_subdirectory(subdir)
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment