diff options
author | Allen Byrne <byrn@hdfgroup.org> | 2016-07-12 17:11:59 (GMT) |
---|---|---|
committer | Allen Byrne <byrn@hdfgroup.org> | 2016-07-12 17:11:59 (GMT) |
commit | 79d909194836c3847669acb78cad15d743f8a135 (patch) | |
tree | 8b75784b9a51cdebde6f5ecb67126bd6aa131a79 /hl/tools/gif2h5/CMakeTests.cmake | |
parent | e1d50d498a0affbbd6e088b524fd495ea95dea88 (diff) | |
download | hdf5-79d909194836c3847669acb78cad15d743f8a135.zip hdf5-79d909194836c3847669acb78cad15d743f8a135.tar.gz hdf5-79d909194836c3847669acb78cad15d743f8a135.tar.bz2 |
[svn-r30170] HDFFV-9946: condense cygwin autotools config files to a single file. Avoid getpwuid function for cygwin.
Diffstat (limited to 'hl/tools/gif2h5/CMakeTests.cmake')
-rw-r--r-- | hl/tools/gif2h5/CMakeTests.cmake | 41 |
1 files changed, 41 insertions, 0 deletions
diff --git a/hl/tools/gif2h5/CMakeTests.cmake b/hl/tools/gif2h5/CMakeTests.cmake new file mode 100644 index 0000000..1cffe55 --- /dev/null +++ b/hl/tools/gif2h5/CMakeTests.cmake @@ -0,0 +1,41 @@ + +############################################################################## +############################################################################## +### T E S T I N G ### +############################################################################## +############################################################################## + +# Make testfiles dir under build dir +file (MAKE_DIRECTORY "${PROJECT_BINARY_DIR}/testfiles") + +# +# copy test files from source to build dir +# +HDFTEST_COPY_FILE("${HDF5_HL_TOOLS_GIF2H5_SOURCE_DIR}/testfiles/image1.gif" "${PROJECT_BINARY_DIR}/testfiles/image1.gif" "gif2h5_files") +HDFTEST_COPY_FILE("${HDF5_HL_TOOLS_GIF2H5_SOURCE_DIR}/testfiles/h52giftst.h5" "${PROJECT_BINARY_DIR}/testfiles/h52giftst.h5" "gif2h5_files") +HDFTEST_COPY_FILE("${HDF5_HL_TOOLS_GIF2H5_SOURCE_DIR}/testfiles/ex_image2.h5" "${PROJECT_BINARY_DIR}/testfiles/ex_image2.h5" "gif2h5_files") +add_custom_target(gif2h5_files ALL COMMENT "Copying files needed by gif2h5 tests" DEPENDS ${gif2h5_files_list}) + +# Remove any output file left over from previous test run +add_test ( + NAME HL_TOOLS-clear-objects + COMMAND ${CMAKE_COMMAND} + -E remove + image1.gif + image1.h5 + image.gif + image24.gif +) + +add_test (NAME HL_TOOLS_gif2h5 COMMAND $<TARGET_FILE:gif2h5> testfiles/image1.gif image1.h5) + +add_test (NAME HL_TOOLS_h52gif COMMAND $<TARGET_FILE:h52gif> testfiles/h52giftst.h5 image1.gif -i image) + +add_test (NAME HL_TOOLS_h52gif_none COMMAND $<TARGET_FILE:h52gif> testfiles/h52giftst.h5 image.gif -i nosuch_image) +set_tests_properties (HL_TOOLS_h52gif_none PROPERTIES WILL_FAIL "true") + +#add_test (NAME HL_TOOLS_h52gifpal COMMAND $<TARGET_FILE:h52gif> testfiles/h52giftst.h5 image.gif -i palette) +#set_tests_properties (HL_TOOLS_h52gifpal PROPERTIES WILL_FAIL "true") + +add_test (NAME HL_TOOLS_h52gif24bits COMMAND $<TARGET_FILE:h52gif> testfiles/ex_image2.h5 image24.gif -i image24bitpixel) +set_tests_properties (HL_TOOLS_h52gif24bits PROPERTIES WILL_FAIL "true") |