summaryrefslogtreecommitdiffstats
path: root/Tests/CTestTestFailure/CMakeLists.txt
diff options
context:
space:
mode:
authorZach Mullen <zach.mullen@kitware.com>2009-09-18 16:16:46 (GMT)
committerZach Mullen <zach.mullen@kitware.com>2009-09-18 16:16:46 (GMT)
commit78e0bfa0fdd2376e89bb7750904db57b5c8bf104 (patch)
tree8201367a03986be0731ce330acf79921f0a61dd6 /Tests/CTestTestFailure/CMakeLists.txt
parent311eb30672c7f098404a6511f71b930f8aad65d7 (diff)
downloadCMake-78e0bfa0fdd2376e89bb7750904db57b5c8bf104.zip
CMake-78e0bfa0fdd2376e89bb7750904db57b5c8bf104.tar.gz
CMake-78e0bfa0fdd2376e89bb7750904db57b5c8bf104.tar.bz2
Added test coverage for ctest. Covers WILL_FAIL condition, tests that do not build, tests that segfault, and test executable not found (bad command), as well as some pass and fail regular expressions.
Diffstat (limited to 'Tests/CTestTestFailure/CMakeLists.txt')
-rw-r--r--Tests/CTestTestFailure/CMakeLists.txt19
1 files changed, 19 insertions, 0 deletions
diff --git a/Tests/CTestTestFailure/CMakeLists.txt b/Tests/CTestTestFailure/CMakeLists.txt
new file mode 100644
index 0000000..62ce7c5
--- /dev/null
+++ b/Tests/CTestTestFailure/CMakeLists.txt
@@ -0,0 +1,19 @@
+cmake_minimum_required (VERSION 2.6)
+PROJECT(CTestTestFailure)
+
+SET(DART_ROOT "" CACHE STRING "" FORCE)
+ENABLE_TESTING()
+INCLUDE (${CMAKE_ROOT}/Modules/Dart.cmake)
+
+GET_FILENAME_COMPONENT(CTEST_COMMAND "${CMAKE_COMMAND}" PATH)
+SET(CTEST_COMMAND "${CTEST_COMMAND}/ctest")
+
+ADD_EXECUTABLE (NoBuild badCode.cxx)
+TARGET_LINK_LIBRARIES (NoBuild ${EXTRA_LIBS})
+
+ENABLE_TESTING ()
+
+ADD_TEST (TestNoExe NoBuild)
+
+INCLUDE (CTest)
+