summaryrefslogtreecommitdiffstats
path: root/Tests/ComplexOneConfig/Executable
diff options
context:
space:
mode:
authorSebastien Barre <sebastien.barre@kitware.com>2002-01-19 01:32:06 (GMT)
committerSebastien Barre <sebastien.barre@kitware.com>2002-01-19 01:32:06 (GMT)
commitc26008ccf3999156cab5a05172a04c562bed9cc8 (patch)
treeee95576b1664de2b2dbc8d97be121dc168292b9f /Tests/ComplexOneConfig/Executable
parent2b5bb96e2367e28e980d4dcc3ddbcbebe34d08af (diff)
downloadCMake-c26008ccf3999156cab5a05172a04c562bed9cc8.zip
CMake-c26008ccf3999156cab5a05172a04c562bed9cc8.tar.gz
CMake-c26008ccf3999156cab5a05172a04c562bed9cc8.tar.bz2
ENH: Increase test + coverage
Diffstat (limited to 'Tests/ComplexOneConfig/Executable')
-rw-r--r--Tests/ComplexOneConfig/Executable/CMakeLists.txt8
-rw-r--r--Tests/ComplexOneConfig/Executable/complex.cxx40
2 files changed, 45 insertions, 3 deletions
diff --git a/Tests/ComplexOneConfig/Executable/CMakeLists.txt b/Tests/ComplexOneConfig/Executable/CMakeLists.txt
index 4bd1620..15808b4 100644
--- a/Tests/ComplexOneConfig/Executable/CMakeLists.txt
+++ b/Tests/ComplexOneConfig/Executable/CMakeLists.txt
@@ -14,7 +14,13 @@ FIND_LIBRARY(CMAKE_LIB
TARGET_LINK_LIBRARIES(complex ${CMAKE_LIB})
LINK_LIBRARIES(${CMAKE_LIB})
-# More coverage
+#
+# Testing
+#
+ADD_TEST(complex ${Complex_BINARY_DIR}/bin/complex)
+#
+# More coverage
+#
INSTALL_TARGETS(/tmp complex)
INSTALL_PROGRAMS(/tmp complex)
diff --git a/Tests/ComplexOneConfig/Executable/complex.cxx b/Tests/ComplexOneConfig/Executable/complex.cxx
index b2f5162..6a55b5c 100644
--- a/Tests/ComplexOneConfig/Executable/complex.cxx
+++ b/Tests/ComplexOneConfig/Executable/complex.cxx
@@ -106,6 +106,42 @@ int main()
Passed("SHOULD_BE_DEFINED is defined.");
#endif
+#ifdef SHOULD_NOT_BE_DEFINED_AND
+ Failed("IF or SET is broken, SHOULD_NOT_BE_DEFINED_AND is defined.");
+#else
+ Passed("SHOULD_NOT_BE_DEFINED_AND is not defined.");
+#endif
+
+#ifndef SHOULD_BE_DEFINED_AND
+ Failed("IF or SET is broken, SHOULD_BE_DEFINED_AND is not defined.\n");
+#else
+ Passed("SHOULD_BE_DEFINED_AND is defined.");
+#endif
+
+#ifdef SHOULD_NOT_BE_DEFINED_OR
+ Failed("IF or SET is broken, SHOULD_NOT_BE_DEFINED_OR is defined.");
+#else
+ Passed("SHOULD_NOT_BE_DEFINED_OR is not defined.");
+#endif
+
+#ifndef SHOULD_BE_DEFINED_OR
+ Failed("IF or SET is broken, SHOULD_BE_DEFINED_OR is not defined.\n");
+#else
+ Passed("SHOULD_BE_DEFINED_OR is defined.");
+#endif
+
+#ifdef SHOULD_NOT_BE_DEFINED_MATCHES
+ Failed("IF or SET is broken, SHOULD_NOT_BE_DEFINED_MATCHES is defined.");
+#else
+ Passed("SHOULD_NOT_BE_DEFINED_MATCHES is not defined.");
+#endif
+
+#ifndef SHOULD_BE_DEFINED_MATCHES
+ Failed("IF or SET is broken, SHOULD_BE_DEFINED_MATCHES is not defined.\n");
+#else
+ Passed("SHOULD_BE_DEFINED_MATCHES is defined.");
+#endif
+
#ifndef ONE_VAR
Failed("cmakedefine is broken, ONE_VAR is not defined.");
#else
@@ -188,7 +224,7 @@ int main()
Failed("the FIND_FILE or GET_FILENAME_COMPONENT command is broken, "
"FILENAME_VAR_NAME is not defined.");
#else
- if(strcmp(FILENAME_VAR_NAME, "VarTests.txt") != 0)
+ if(strcmp(FILENAME_VAR_NAME, "VarTests.cmake") != 0)
{
Failed("the FIND_FILE or GET_FILENAME_COMPONENT command is broken, "
"FILENAME_VAR_NAME == ", FILENAME_VAR_NAME);
@@ -203,7 +239,7 @@ int main()
Failed("the FIND_FILE or GET_FILENAME_COMPONENT command is broken, "
"FILENAME_VAR_EXT is not defined.");
#else
- if(strcmp(FILENAME_VAR_EXT, ".txt") != 0)
+ if(strcmp(FILENAME_VAR_EXT, ".cmake") != 0)
{
Failed("the FIND_FILE or GET_FILENAME_COMPONENT command is broken, "
"FILENAME_VAR_EXT == ", FILENAME_VAR_EXT);