summaryrefslogtreecommitdiffstats
path: root/test/CMakeTests.cmake
diff options
context:
space:
mode:
Diffstat (limited to 'test/CMakeTests.cmake')
-rw-r--r--test/CMakeTests.cmake128
1 files changed, 128 insertions, 0 deletions
diff --git a/test/CMakeTests.cmake b/test/CMakeTests.cmake
index fe6c695..6532536 100644
--- a/test/CMakeTests.cmake
+++ b/test/CMakeTests.cmake
@@ -463,8 +463,10 @@ set (H5TEST_SEPARATE_TESTS
testhdf5
cache
cache_image
+ external_env
flush1
flush2
+ vds_env
)
foreach (h5_test ${H5_TESTS})
if (NOT h5_test IN_LIST H5TEST_SEPARATE_TESTS)
@@ -558,6 +560,71 @@ if (TEST_CACHE_IMAGE)
)
endif ()
+#-- Adding test for external_env
+add_test (
+ NAME H5TEST-clear-external_env-objects
+ COMMAND ${CMAKE_COMMAND}
+ -D "TEST_PROGRAM=$<TARGET_FILE:external_env>"
+ -D "TEST_ARGS:STRING="
+ -D "TEST_ENV_VAR:STRING=HDF5_EXTFILE_PREFIX"
+ -D "TEST_ENV_VALUE:STRING=\${ORIGIN}"
+ -D "TEST_EXPECT=0"
+ -D "TEST_OUTPUT=external_env.txt"
+ -D "TEST_REFERENCE=external_env.out"
+ -D "TEST_FOLDER=${PROJECT_BINARY_DIR}/H5TEST"
+ -P "${HDF_RESOURCES_EXT_DIR}/runTest.cmake"
+ -E remove
+ extern_1r.raw
+ extern_2r.raw
+ extern_3r.raw
+ extern_4r.raw
+ extern_1w.raw
+ extern_2w.raw
+ extern_3w.raw
+ extern_4w.raw
+ external_env.txt
+ external_env.out
+ WORKING_DIRECTORY
+ ${HDF5_TEST_BINARY_DIR}/H5TEST
+)
+set_tests_properties (H5TEST-clear-external_env-objects PROPERTIES FIXTURES_SETUP external_env_clear_objects)
+add_test (NAME H5TEST-external_env COMMAND $<TARGET_FILE:external_env>)
+set_tests_properties (H5TEST-external_env PROPERTIES
+ FIXTURES_REQUIRED external_env_clear_objects
+ ENVIRONMENT "srcdir=${HDF5_TEST_BINARY_DIR}/H5TEST;HDF5TestExpress=${HDF_TEST_EXPRESS}"
+ WORKING_DIRECTORY ${HDF5_TEST_BINARY_DIR}/H5TEST
+)
+
+#-- Adding test for vds_env
+add_test (
+ NAME H5TEST-clear-vds_env-objects
+ COMMAND ${CMAKE_COMMAND}
+ -D "TEST_PROGRAM=$<TARGET_FILE:vds_env>"
+ -D "TEST_ARGS:STRING="
+ -D "TEST_ENV_VAR:STRING=HDF5_VDS_PREFIX"
+ -D "TEST_ENV_VALUE:STRING=\${ORIGIN}/tmp"
+ -D "TEST_EXPECT=0"
+ -D "TEST_OUTPUT=vds_env.txt"
+ -D "TEST_REFERENCE=vds_env.out"
+ -D "TEST_FOLDER=${PROJECT_BINARY_DIR}/H5TEST"
+ -P "${HDF_RESOURCES_EXT_DIR}/runTest.cmake"
+ -E remove
+ vds_virt_0.h5
+ vds_virt_3.h5
+ vds_src_2.h5
+ vds_env.txt
+ vds_env.out
+ WORKING_DIRECTORY
+ ${HDF5_TEST_BINARY_DIR}/H5TEST
+)
+set_tests_properties (H5TEST-clear-vds_env-objects PROPERTIES FIXTURES_SETUP vds_env_clear_objects)
+add_test (NAME H5TEST-vds_env COMMAND $<TARGET_FILE:vds_env>)
+set_tests_properties (H5TEST-vds_env PROPERTIES
+ FIXTURES_REQUIRED vds_env_clear_objects
+ ENVIRONMENT "srcdir=${HDF5_TEST_BINARY_DIR}/H5TEST;HDF5TestExpress=${HDF_TEST_EXPRESS}"
+ WORKING_DIRECTORY ${HDF5_TEST_BINARY_DIR}/H5TEST
+)
+
#-- Adding test for flush1/2
add_test (NAME H5TEST-clear-flush-objects
COMMAND ${CMAKE_COMMAND}
@@ -787,6 +854,67 @@ set_tests_properties (H5TEST-links_env PROPERTIES
WORKING_DIRECTORY ${HDF5_TEST_BINARY_DIR}/H5TEST
)
+ #-- Adding test for external_env
+ add_test (NAME H5TEST-shared-clear-external_env-objects
+ COMMAND ${CMAKE_COMMAND}
+ -E remove
+ extern_1r.raw
+ extern_2r.raw
+ extern_3r.raw
+ extern_4r.raw
+ extern_1w.raw
+ extern_2w.raw
+ extern_3w.raw
+ extern_4w.raw
+ WORKING_DIRECTORY
+ ${HDF5_TEST_BINARY_DIR}/H5TEST-shared
+ )
+ set_tests_properties (H5TEST-shared-clear-external_env-objects PROPERTIES FIXTURES_SETUP shared_external_env_clear_objects)
+ add_test (NAME H5TEST-shared-external_env COMMAND "${CMAKE_COMMAND}"
+ -D "TEST_PROGRAM=$<TARGET_FILE:external_env-shared>"
+ -D "TEST_ARGS:STRING="
+ -D "TEST_ENV_VAR:STRING=HDF5_EXTFILE_PREFIX"
+ -D "TEST_ENV_VALUE:STRING=\${ORIGIN}"
+ -D "TEST_EXPECT=0"
+ -D "TEST_OUTPUT=external_env.txt"
+ -D "TEST_REFERENCE=external_env.out"
+ -D "TEST_FOLDER=${PROJECT_BINARY_DIR}/H5TEST-shared"
+ -P "${HDF_RESOURCES_EXT_DIR}/runTest.cmake"
+ )
+ set_tests_properties (H5TEST-shared-external_env PROPERTIES
+ FIXTURES_REQUIRED shared_external_env_clear_objects
+ ENVIRONMENT "srcdir=${HDF5_TEST_BINARY_DIR}/H5TEST-shared"
+ WORKING_DIRECTORY ${HDF5_TEST_BINARY_DIR}/H5TEST-shared
+ )
+
+ #-- Adding test for vds_env
+ add_test (NAME H5TEST-shared-clear-vds_env-objects
+ COMMAND ${CMAKE_COMMAND}
+ -E remove
+ vds_virt_0.h5
+ vds_virt_3.h5
+ vds_src_2.h5
+ WORKING_DIRECTORY
+ ${HDF5_TEST_BINARY_DIR}/H5TEST-shared
+ )
+ set_tests_properties (H5TEST-shared-clear-vds_env-objects PROPERTIES FIXTURES_SETUP shared_vds_env_clear_objects)
+ add_test (NAME H5TEST-shared-vds_env COMMAND "${CMAKE_COMMAND}"
+ -D "TEST_PROGRAM=$<TARGET_FILE:vds_env-shared>"
+ -D "TEST_ARGS:STRING="
+ -D "TEST_ENV_VAR:STRING=HDF5_VDS_PREFIX"
+ -D "TEST_ENV_VALUE:STRING=\${ORIGIN}/tmp"
+ -D "TEST_EXPECT=0"
+ -D "TEST_OUTPUT=vds_env.txt"
+ -D "TEST_REFERENCE=vds_env.out"
+ -D "TEST_FOLDER=${PROJECT_BINARY_DIR}/H5TEST-shared"
+ -P "${HDF_RESOURCES_EXT_DIR}/runTest.cmake"
+ )
+ set_tests_properties (H5TEST-shared-vds_env PROPERTIES
+ FIXTURES_REQUIRED shared_vds_env_clear_objects
+ ENVIRONMENT "srcdir=${HDF5_TEST_BINARY_DIR}/H5TEST-shared"
+ WORKING_DIRECTORY ${HDF5_TEST_BINARY_DIR}/H5TEST-shared
+ )
+
if (NOT BUILD_SHARED_LIBS)
#-- Adding test for libinfo
add_test (NAME H5TEST-testlibinfo