summaryrefslogtreecommitdiffstats
path: root/config/cmake/vfdTest.cmake
diff options
context:
space:
mode:
authorAllen Byrne <byrn@hdfgroup.org>2014-03-11 21:14:57 (GMT)
committerAllen Byrne <byrn@hdfgroup.org>2014-03-11 21:14:57 (GMT)
commita3292a77cef4fc760aab8b496cd6b105c5370890 (patch)
tree188bd8e5268775213f516dc7062ead790a9997b1 /config/cmake/vfdTest.cmake
parent5b7c8c7a7d0b40e36a744f7e1dc68cd189e321b2 (diff)
downloadhdf5-a3292a77cef4fc760aab8b496cd6b105c5370890.zip
hdf5-a3292a77cef4fc760aab8b496cd6b105c5370890.tar.gz
hdf5-a3292a77cef4fc760aab8b496cd6b105c5370890.tar.bz2
[svn-r24781] HDFFV-8700 -
KitWare recommendations: Change CMake commands to lower case. Remove INCLUDE_DIRECTORIES in src for target level includes. Change ADD_DEFINITIONS package debug defines into CMake option. Remove -DNDEBUG
Diffstat (limited to 'config/cmake/vfdTest.cmake')
-rw-r--r--config/cmake/vfdTest.cmake56
1 files changed, 28 insertions, 28 deletions
diff --git a/config/cmake/vfdTest.cmake b/config/cmake/vfdTest.cmake
index 2e854fb..f12dee7 100644
--- a/config/cmake/vfdTest.cmake
+++ b/config/cmake/vfdTest.cmake
@@ -2,27 +2,27 @@
# Exit status of command can also be compared.
# arguments checking
-IF (NOT TEST_PROGRAM)
- MESSAGE (FATAL_ERROR "Require TEST_PROGRAM to be defined")
-ENDIF (NOT TEST_PROGRAM)
-#IF (NOT TEST_ARGS)
-# MESSAGE (STATUS "Require TEST_ARGS to be defined")
-#ENDIF (NOT TEST_ARGS)
-#IF (NOT TEST_EXPECT)
-# MESSAGE (STATUS "Require TEST_EXPECT to be defined")
-#ENDIF (NOT TEST_EXPECT)
-IF (NOT TEST_FOLDER)
- MESSAGE ( FATAL_ERROR "Require TEST_FOLDER to be defined")
-ENDIF (NOT TEST_FOLDER)
-IF (NOT TEST_VFD)
- MESSAGE (FATAL_ERROR "Require TEST_VFD to be defined")
-ENDIF (NOT TEST_VFD)
-
-SET (ERROR_APPEND 1)
-
-MESSAGE (STATUS "USING ${TEST_VFD} ON COMMAND: ${TEST_PROGRAM} ${TEST_ARGS}")
-
-SET (ENV{HDF5_DRIVER} "${TEST_VFD}")
+if (NOT TEST_PROGRAM)
+ message (FATAL_ERROR "Require TEST_PROGRAM to be defined")
+endif (NOT TEST_PROGRAM)
+#if (NOT TEST_ARGS)
+# message (STATUS "Require TEST_ARGS to be defined")
+#endif (NOT TEST_ARGS)
+#if (NOT TEST_EXPECT)
+# message (STATUS "Require TEST_EXPECT to be defined")
+#endif (NOT TEST_EXPECT)
+if (NOT TEST_FOLDER)
+ message ( FATAL_ERROR "Require TEST_FOLDER to be defined")
+endif (NOT TEST_FOLDER)
+if (NOT TEST_VFD)
+ message (FATAL_ERROR "Require TEST_VFD to be defined")
+endif (NOT TEST_VFD)
+
+set (ERROR_APPEND 1)
+
+message (STATUS "USING ${TEST_VFD} ON COMMAND: ${TEST_PROGRAM} ${TEST_ARGS}")
+
+set (ENV{HDF5_DRIVER} "${TEST_VFD}")
# run the test program, capture the stdout/stderr and the result var
EXECUTE_PROCESS (
COMMAND ${TEST_PROGRAM} ${TEST_ARGS}
@@ -33,18 +33,18 @@ EXECUTE_PROCESS (
ERROR_VARIABLE TEST_ERROR
)
-MESSAGE (STATUS "COMMAND Result: ${TEST_RESULT}")
+message (STATUS "COMMAND Result: ${TEST_RESULT}")
-IF (ERROR_APPEND)
+if (ERROR_APPEND)
FILE (READ ${TEST_FOLDER}/${TEST_OUTPUT}_${TEST_VFD}.err TEST_STREAM)
FILE (APPEND ${TEST_FOLDER}/${TEST_OUTPUT}_${TEST_VFD}.out "${TEST_STREAM}")
-ENDIF (ERROR_APPEND)
+endif (ERROR_APPEND)
# if the return value is !=${TEST_EXPECT} bail out
-IF (NOT ${TEST_RESULT} STREQUAL ${TEST_EXPECT})
- MESSAGE ( FATAL_ERROR "Failed: Test program ${TEST_PROGRAM} exited != ${TEST_EXPECT}.\n${TEST_ERROR}")
-ENDIF (NOT ${TEST_RESULT} STREQUAL ${TEST_EXPECT})
+if (NOT ${TEST_RESULT} STREQUAL ${TEST_EXPECT})
+ message ( FATAL_ERROR "Failed: Test program ${TEST_PROGRAM} exited != ${TEST_EXPECT}.\n${TEST_ERROR}")
+endif (NOT ${TEST_RESULT} STREQUAL ${TEST_EXPECT})
# everything went fine...
-MESSAGE ("Passed: The ${TEST_PROGRAM} program used vfd ${TEST_VFD}")
+message ("Passed: The ${TEST_PROGRAM} program used vfd ${TEST_VFD}")