summaryrefslogtreecommitdiffstats
path: root/tools/h5copy
diff options
context:
space:
mode:
authorAllen Byrne <byrn@hdfgroup.org>2011-03-08 15:11:02 (GMT)
committerAllen Byrne <byrn@hdfgroup.org>2011-03-08 15:11:02 (GMT)
commitfe660a8da4a41719afc009f7fedea8164f948f35 (patch)
tree865182e1acb79852f8128aab11aaab8c59b8ee25 /tools/h5copy
parent6d350b411235b07f1ddbbc209204111a6ad31746 (diff)
downloadhdf5-fe660a8da4a41719afc009f7fedea8164f948f35.zip
hdf5-fe660a8da4a41719afc009f7fedea8164f948f35.tar.gz
hdf5-fe660a8da4a41719afc009f7fedea8164f948f35.tar.bz2
[svn-r20197] Change test macro to allow control of infile and outfile parameters
Diffstat (limited to 'tools/h5copy')
-rw-r--r--tools/h5copy/CMakeLists.txt12
1 files changed, 8 insertions, 4 deletions
diff --git a/tools/h5copy/CMakeLists.txt b/tools/h5copy/CMakeLists.txt
index 0cd273c..180dc9d 100644
--- a/tools/h5copy/CMakeLists.txt
+++ b/tools/h5copy/CMakeLists.txt
@@ -77,22 +77,26 @@ IF (BUILD_TESTING)
##############################################################################
MACRO (ADD_H5_TEST testname resultcode testfile vparam srcname dstname)
+ ADD_H5COPY_TEST (${testname} ${resultcode} ${testfile}.h5 ${testfile}.out.h5 ${vparam} ${srcname} ${dstname} ${ARGN})
+ ENDMACRO (ADD_H5_TEST testname resultcode testfile vparam srcname dstname)
+
+ MACRO (ADD_H5COPY_TEST testname resultcode infile outfile vparam srcname dstname)
IF (NOT "${ARGN}" STREQUAL "")
ADD_TEST (
NAME H5COPY-${testname}
- COMMAND $<TARGET_FILE:h5copy> -f ${ARGN} -i ./testfiles/${testfile}.h5 -o ./testfiles/${testfile}.out.h5 -${vparam} -s ${srcname} -d ${dstname}
+ COMMAND $<TARGET_FILE:h5copy> -f ${ARGN} -i ./testfiles/${infile} -o ./testfiles/${outfile} -${vparam} -s ${srcname} -d ${dstname}
)
ELSE (NOT "${ARGN}" STREQUAL "")
ADD_TEST (
NAME H5COPY-${testname}
- COMMAND $<TARGET_FILE:h5copy> -i ./testfiles/${testfile}.h5 -o ./testfiles/${testfile}.out.h5 -${vparam} -s ${srcname} -d ${dstname}
+ COMMAND $<TARGET_FILE:h5copy> -i ./testfiles/${infile} -o ./testfiles/${outfile} -${vparam} -s ${srcname} -d ${dstname}
)
ENDIF (NOT "${ARGN}" STREQUAL "")
IF (NOT ${resultcode} STREQUAL "2")
ADD_TEST (
NAME H5COPY-DIFF_${testname}
- COMMAND $<TARGET_FILE:h5diff> -q ./testfiles/${testfile}.h5 ./testfiles/${testfile}.out.h5 ${srcname} ${dstname}
+ COMMAND $<TARGET_FILE:h5diff> -q ./testfiles/${infile} ./testfiles/${outfile} ${srcname} ${dstname}
)
SET_TESTS_PROPERTIES(H5COPY-DIFF_${testname} PROPERTIES DEPENDS H5COPY-${testname})
IF (${resultcode} STREQUAL "1")
@@ -103,7 +107,7 @@ IF (BUILD_TESTING)
SET_TESTS_PROPERTIES (H5COPY-${testname} PROPERTIES DEPENDS ${last_test})
ENDIF (NOT "${last_test}" STREQUAL "")
SET (last_test "H5COPY-DIFF_${testname}")
- ENDMACRO (ADD_H5_TEST testname resultcode testfile vparam srcname dstname)
+ ENDMACRO (ADD_H5COPY_TEST testname resultcode testfile vparam srcname dstname)
MACRO (ADD_H5LS_TEST file filetest)
# If using memchecker add tests without using scripts