diff options
Diffstat (limited to 'tools/test/misc')
63 files changed, 254 insertions, 122 deletions
diff --git a/tools/test/misc/CMakeTestsClear.cmake b/tools/test/misc/CMakeTestsClear.cmake index a554972..2f3c62f 100644 --- a/tools/test/misc/CMakeTestsClear.cmake +++ b/tools/test/misc/CMakeTestsClear.cmake @@ -63,11 +63,14 @@ h5clear_open_fail.err ) - foreach (h5_file ${HDF5_TEST_FILES} ${HDF5_SEC2_TEST_FILES} ${HDF5_REFERENCE_TEST_FILES}) + foreach (h5_file ${HDF5_TEST_FILES} ${HDF5_SEC2_TEST_FILES}) HDFTEST_COPY_FILE("${PROJECT_SOURCE_DIR}/testfiles/${h5_file}" "${PROJECT_BINARY_DIR}/testfiles/${h5_file}" "h5clear_files") endforeach () + foreach (h5_file ${HDF5_REFERENCE_TEST_FILES}) + HDFTEST_COPY_FILE("${PROJECT_SOURCE_DIR}/expected/${h5_file}" "${PROJECT_BINARY_DIR}/testfiles/${h5_file}" "h5clear_files") + endforeach () foreach (h5_file ${HDF5_REFERENCE_ERR_FILES}) - HDFTEST_COPY_FILE("${PROJECT_SOURCE_DIR}/testfiles/${h5_file}" "${PROJECT_BINARY_DIR}/testfiles/${h5_file}" "h5clear_files") + HDFTEST_COPY_FILE("${PROJECT_SOURCE_DIR}/expected/${h5_file}" "${PROJECT_BINARY_DIR}/testfiles/${h5_file}" "h5clear_files") endforeach () # make second copy of h5clear_sec2.h5 foreach (h5_file ${HDF5_SEC2_TEST_FILES}) diff --git a/tools/test/misc/CMakeTestsMkgrp.cmake b/tools/test/misc/CMakeTestsMkgrp.cmake index b4d1a56..9e4f739 100644 --- a/tools/test/misc/CMakeTestsMkgrp.cmake +++ b/tools/test/misc/CMakeTestsMkgrp.cmake @@ -40,10 +40,10 @@ file (MAKE_DIRECTORY "${PROJECT_BINARY_DIR}/testfiles") foreach (h5_mkgrp_file ${HDF5_MKGRP_TEST_FILES}) - HDFTEST_COPY_FILE("${HDF5_TOOLS_DIR}/testfiles/${h5_mkgrp_file}" "${PROJECT_BINARY_DIR}/testfiles/${h5_mkgrp_file}" "h5mkgrp_files") + HDFTEST_COPY_FILE("${PROJECT_SOURCE_DIR}/expected/${h5_mkgrp_file}" "${PROJECT_BINARY_DIR}/testfiles/${h5_mkgrp_file}" "h5mkgrp_files") endforeach () - HDFTEST_COPY_FILE("${HDF5_TOOLS_TEST_MISC_SOURCE_DIR}/testfiles/h5mkgrp_help.txt" "${PROJECT_BINARY_DIR}/testfiles/h5mkgrp_help.txt" "h5mkgrp_files") + HDFTEST_COPY_FILE("${PROJECT_SOURCE_DIR}/expected/h5mkgrp_help.txt" "${PROJECT_BINARY_DIR}/testfiles/h5mkgrp_help.txt" "h5mkgrp_files") add_custom_target(h5mkgrp_files ALL COMMENT "Copying files needed by h5mkgrp tests" DEPENDS ${h5mkgrp_files_list}) configure_file (${HDF5_TOOLS_TEST_MISC_SOURCE_DIR}/testfiles/h5mkgrp_version.txt.in ${PROJECT_BINARY_DIR}/testfiles/h5mkgrp_version.txt @ONLY) diff --git a/tools/test/misc/CMakeTestsRepart.cmake b/tools/test/misc/CMakeTestsRepart.cmake index 04c74ec..764778e 100644 --- a/tools/test/misc/CMakeTestsRepart.cmake +++ b/tools/test/misc/CMakeTestsRepart.cmake @@ -41,7 +41,7 @@ ) foreach (h5_file ${HDF5_REFERENCE_TEST_FILES}) - HDFTEST_COPY_FILE("${HDF5_TOOLS_DIR}/testfiles/${h5_file}" "${PROJECT_BINARY_DIR}/${h5_file}" "h5repart_files") + HDFTEST_COPY_FILE("${PROJECT_SOURCE_DIR}/testfiles/${h5_file}" "${PROJECT_BINARY_DIR}/${h5_file}" "h5repart_files") endforeach () add_custom_target(h5repart_files ALL COMMENT "Copying files needed by h5repart tests" DEPENDS ${h5repart_files_list}) diff --git a/tools/test/misc/clear_open_chk.c b/tools/test/misc/clear_open_chk.c index 3095618..8abd4e5 100644 --- a/tools/test/misc/clear_open_chk.c +++ b/tools/test/misc/clear_open_chk.c @@ -47,10 +47,10 @@ main(int argc, char *argv[]) } /* Get the file name */ - fname = HDstrdup(argv[1]); + fname = strdup(argv[1]); /* Try opening the file */ - if ((fid = h5tools_fopen(fname, H5F_ACC_RDONLY, H5P_DEFAULT, FALSE, NULL, (size_t)0)) < 0) { + if ((fid = h5tools_fopen(fname, H5F_ACC_RDONLY, H5P_DEFAULT, false, NULL, (size_t)0)) < 0) { fprintf(stderr, "clear_open_chk: unable to open the file\n"); free(fname); exit(EXIT_FAILURE); diff --git a/tools/test/misc/testfiles/h5clear_equal_after_size.ddl b/tools/test/misc/expected/h5clear_equal_after_size.ddl index 1b9a4e4..1b9a4e4 100644 --- a/tools/test/misc/testfiles/h5clear_equal_after_size.ddl +++ b/tools/test/misc/expected/h5clear_equal_after_size.ddl diff --git a/tools/test/misc/testfiles/h5clear_equal_before_size.ddl b/tools/test/misc/expected/h5clear_equal_before_size.ddl index 9beed42..9beed42 100644 --- a/tools/test/misc/testfiles/h5clear_equal_before_size.ddl +++ b/tools/test/misc/expected/h5clear_equal_before_size.ddl diff --git a/tools/test/misc/testfiles/h5clear_greater_after_size.ddl b/tools/test/misc/expected/h5clear_greater_after_size.ddl index 74c8f19..74c8f19 100644 --- a/tools/test/misc/testfiles/h5clear_greater_after_size.ddl +++ b/tools/test/misc/expected/h5clear_greater_after_size.ddl diff --git a/tools/test/misc/testfiles/h5clear_greater_before_size.ddl b/tools/test/misc/expected/h5clear_greater_before_size.ddl index 03b22fb..03b22fb 100644 --- a/tools/test/misc/testfiles/h5clear_greater_before_size.ddl +++ b/tools/test/misc/expected/h5clear_greater_before_size.ddl diff --git a/tools/test/misc/testfiles/h5clear_less_after_size.ddl b/tools/test/misc/expected/h5clear_less_after_size.ddl index bedf0d2..bedf0d2 100644 --- a/tools/test/misc/testfiles/h5clear_less_after_size.ddl +++ b/tools/test/misc/expected/h5clear_less_after_size.ddl diff --git a/tools/test/misc/testfiles/h5clear_less_before_size.ddl b/tools/test/misc/expected/h5clear_less_before_size.ddl index 50ba4c4..50ba4c4 100644 --- a/tools/test/misc/testfiles/h5clear_less_before_size.ddl +++ b/tools/test/misc/expected/h5clear_less_before_size.ddl diff --git a/tools/test/misc/testfiles/h5clear_missing_file.ddl b/tools/test/misc/expected/h5clear_missing_file.ddl index c7a2118..c7a2118 100644 --- a/tools/test/misc/testfiles/h5clear_missing_file.ddl +++ b/tools/test/misc/expected/h5clear_missing_file.ddl diff --git a/tools/test/misc/testfiles/h5clear_missing_file.err b/tools/test/misc/expected/h5clear_missing_file.err index ea21b76..ea21b76 100644 --- a/tools/test/misc/testfiles/h5clear_missing_file.err +++ b/tools/test/misc/expected/h5clear_missing_file.err diff --git a/tools/test/misc/testfiles/h5clear_no_mdc_image.err b/tools/test/misc/expected/h5clear_no_mdc_image.err index f5acd71..f5acd71 100644 --- a/tools/test/misc/testfiles/h5clear_no_mdc_image.err +++ b/tools/test/misc/expected/h5clear_no_mdc_image.err diff --git a/tools/test/misc/testfiles/h5clear_noclose_after_size.ddl b/tools/test/misc/expected/h5clear_noclose_after_size.ddl index 7846b47..7846b47 100644 --- a/tools/test/misc/testfiles/h5clear_noclose_after_size.ddl +++ b/tools/test/misc/expected/h5clear_noclose_after_size.ddl diff --git a/tools/test/misc/testfiles/h5clear_noclose_before_size.ddl b/tools/test/misc/expected/h5clear_noclose_before_size.ddl index f294a6d..f294a6d 100644 --- a/tools/test/misc/testfiles/h5clear_noclose_before_size.ddl +++ b/tools/test/misc/expected/h5clear_noclose_before_size.ddl diff --git a/tools/test/misc/testfiles/h5clear_open_fail.err b/tools/test/misc/expected/h5clear_open_fail.err index 895ecd4..895ecd4 100644 --- a/tools/test/misc/testfiles/h5clear_open_fail.err +++ b/tools/test/misc/expected/h5clear_open_fail.err diff --git a/tools/test/misc/testfiles/h5clear_status_noclose_after_size.ddl b/tools/test/misc/expected/h5clear_status_noclose_after_size.ddl index 7846b47..7846b47 100644 --- a/tools/test/misc/testfiles/h5clear_status_noclose_after_size.ddl +++ b/tools/test/misc/expected/h5clear_status_noclose_after_size.ddl diff --git a/tools/test/misc/testfiles/h5clear_usage.ddl b/tools/test/misc/expected/h5clear_usage.ddl index c7a2118..c7a2118 100644 --- a/tools/test/misc/testfiles/h5clear_usage.ddl +++ b/tools/test/misc/expected/h5clear_usage.ddl diff --git a/tools/test/misc/testfiles/h5clear_user_equal_after_size.ddl b/tools/test/misc/expected/h5clear_user_equal_after_size.ddl index 028e134..028e134 100644 --- a/tools/test/misc/testfiles/h5clear_user_equal_after_size.ddl +++ b/tools/test/misc/expected/h5clear_user_equal_after_size.ddl diff --git a/tools/test/misc/testfiles/h5clear_user_equal_before_size.ddl b/tools/test/misc/expected/h5clear_user_equal_before_size.ddl index ef7c391..ef7c391 100644 --- a/tools/test/misc/testfiles/h5clear_user_equal_before_size.ddl +++ b/tools/test/misc/expected/h5clear_user_equal_before_size.ddl diff --git a/tools/test/misc/testfiles/h5clear_user_greater_after_size.ddl b/tools/test/misc/expected/h5clear_user_greater_after_size.ddl index 9d7de6f..9d7de6f 100644 --- a/tools/test/misc/testfiles/h5clear_user_greater_after_size.ddl +++ b/tools/test/misc/expected/h5clear_user_greater_after_size.ddl diff --git a/tools/test/misc/testfiles/h5clear_user_greater_before_size.ddl b/tools/test/misc/expected/h5clear_user_greater_before_size.ddl index c3fe625..c3fe625 100644 --- a/tools/test/misc/testfiles/h5clear_user_greater_before_size.ddl +++ b/tools/test/misc/expected/h5clear_user_greater_before_size.ddl diff --git a/tools/test/misc/testfiles/h5clear_user_less_after_size.ddl b/tools/test/misc/expected/h5clear_user_less_after_size.ddl index 02c0d2a..02c0d2a 100644 --- a/tools/test/misc/testfiles/h5clear_user_less_after_size.ddl +++ b/tools/test/misc/expected/h5clear_user_less_after_size.ddl diff --git a/tools/test/misc/testfiles/h5clear_user_less_before_size.ddl b/tools/test/misc/expected/h5clear_user_less_before_size.ddl index 0651c2b..0651c2b 100644 --- a/tools/test/misc/testfiles/h5clear_user_less_before_size.ddl +++ b/tools/test/misc/expected/h5clear_user_less_before_size.ddl diff --git a/tools/test/misc/testfiles/h5mkgrp_help.txt b/tools/test/misc/expected/h5mkgrp_help.txt index d01fbee..d01fbee 100644 --- a/tools/test/misc/testfiles/h5mkgrp_help.txt +++ b/tools/test/misc/expected/h5mkgrp_help.txt diff --git a/tools/test/misc/expected/h5mkgrp_nested_lp.ls b/tools/test/misc/expected/h5mkgrp_nested_lp.ls new file mode 100644 index 0000000..1fe8ce8 --- /dev/null +++ b/tools/test/misc/expected/h5mkgrp_nested_lp.ls @@ -0,0 +1,13 @@ +Opened "h5mkgrp_nested_lp.h5" with sec2 driver. +/ Group + Location: 1:48 + Links: 1 + Modified: XXXX-XX-XX XX:XX:XX XXX +/one Group + Location: 1:195 + Links: 1 + Modified: XXXX-XX-XX XX:XX:XX XXX +/one/two Group + Location: 1:342 + Links: 1 + Modified: XXXX-XX-XX XX:XX:XX XXX diff --git a/tools/test/misc/expected/h5mkgrp_nested_mult_lp.ls b/tools/test/misc/expected/h5mkgrp_nested_mult_lp.ls new file mode 100644 index 0000000..50380ec --- /dev/null +++ b/tools/test/misc/expected/h5mkgrp_nested_mult_lp.ls @@ -0,0 +1,21 @@ +Opened "h5mkgrp_nested_mult_lp.h5" with sec2 driver. +/ Group + Location: 1:48 + Links: 1 + Modified: XXXX-XX-XX XX:XX:XX XXX +/one Group + Location: 1:195 + Links: 1 + Modified: XXXX-XX-XX XX:XX:XX XXX +/one/two Group + Location: 1:342 + Links: 1 + Modified: XXXX-XX-XX XX:XX:XX XXX +/three Group + Location: 1:489 + Links: 1 + Modified: XXXX-XX-XX XX:XX:XX XXX +/three/four Group + Location: 1:636 + Links: 1 + Modified: XXXX-XX-XX XX:XX:XX XXX diff --git a/tools/test/misc/expected/h5mkgrp_nested_mult_p.ls b/tools/test/misc/expected/h5mkgrp_nested_mult_p.ls new file mode 100644 index 0000000..f2b3b4b --- /dev/null +++ b/tools/test/misc/expected/h5mkgrp_nested_mult_p.ls @@ -0,0 +1,16 @@ +Opened "h5mkgrp_nested_mult_p.h5" with sec2 driver. +/ Group + Location: 1:96 + Links: 1 +/one Group + Location: 1:800 + Links: 1 +/one/two Group + Location: 1:1832 + Links: 1 +/three Group + Location: 1:2864 + Links: 1 +/three/four Group + Location: 1:3568 + Links: 1 diff --git a/tools/test/misc/expected/h5mkgrp_nested_p.ls b/tools/test/misc/expected/h5mkgrp_nested_p.ls new file mode 100644 index 0000000..3034dbb --- /dev/null +++ b/tools/test/misc/expected/h5mkgrp_nested_p.ls @@ -0,0 +1,10 @@ +Opened "h5mkgrp_nested_p.h5" with sec2 driver. +/ Group + Location: 1:96 + Links: 1 +/one Group + Location: 1:800 + Links: 1 +/one/two Group + Location: 1:1832 + Links: 1 diff --git a/tools/test/misc/expected/h5mkgrp_several.ls b/tools/test/misc/expected/h5mkgrp_several.ls new file mode 100644 index 0000000..68a3f9c --- /dev/null +++ b/tools/test/misc/expected/h5mkgrp_several.ls @@ -0,0 +1,10 @@ +Opened "h5mkgrp_several.h5" with sec2 driver. +/ Group + Location: 1:96 + Links: 1 +/one Group + Location: 1:800 + Links: 1 +/two Group + Location: 1:1832 + Links: 1 diff --git a/tools/test/misc/expected/h5mkgrp_several_l.ls b/tools/test/misc/expected/h5mkgrp_several_l.ls new file mode 100644 index 0000000..5e1b4be --- /dev/null +++ b/tools/test/misc/expected/h5mkgrp_several_l.ls @@ -0,0 +1,13 @@ +Opened "h5mkgrp_several_l.h5" with sec2 driver. +/ Group + Location: 1:48 + Links: 1 + Modified: XXXX-XX-XX XX:XX:XX XXX +/one Group + Location: 1:195 + Links: 1 + Modified: XXXX-XX-XX XX:XX:XX XXX +/two Group + Location: 1:342 + Links: 1 + Modified: XXXX-XX-XX XX:XX:XX XXX diff --git a/tools/test/misc/expected/h5mkgrp_several_p.ls b/tools/test/misc/expected/h5mkgrp_several_p.ls new file mode 100644 index 0000000..43f1ce5 --- /dev/null +++ b/tools/test/misc/expected/h5mkgrp_several_p.ls @@ -0,0 +1,10 @@ +Opened "h5mkgrp_several_p.h5" with sec2 driver. +/ Group + Location: 1:96 + Links: 1 +/one Group + Location: 1:800 + Links: 1 +/two Group + Location: 1:1832 + Links: 1 diff --git a/tools/test/misc/expected/h5mkgrp_several_v.ls b/tools/test/misc/expected/h5mkgrp_several_v.ls new file mode 100644 index 0000000..a6df87b --- /dev/null +++ b/tools/test/misc/expected/h5mkgrp_several_v.ls @@ -0,0 +1,10 @@ +Opened "h5mkgrp_several_v.h5" with sec2 driver. +/ Group + Location: 1:96 + Links: 1 +/one Group + Location: 1:800 + Links: 1 +/two Group + Location: 1:1832 + Links: 1 diff --git a/tools/test/misc/expected/h5mkgrp_single.ls b/tools/test/misc/expected/h5mkgrp_single.ls new file mode 100644 index 0000000..f2bd01c --- /dev/null +++ b/tools/test/misc/expected/h5mkgrp_single.ls @@ -0,0 +1,7 @@ +Opened "h5mkgrp_single.h5" with sec2 driver. +/ Group + Location: 1:96 + Links: 1 +/single Group + Location: 1:800 + Links: 1 diff --git a/tools/test/misc/expected/h5mkgrp_single_l.ls b/tools/test/misc/expected/h5mkgrp_single_l.ls new file mode 100644 index 0000000..1763a61 --- /dev/null +++ b/tools/test/misc/expected/h5mkgrp_single_l.ls @@ -0,0 +1,9 @@ +Opened "h5mkgrp_single_l.h5" with sec2 driver. +/ Group + Location: 1:48 + Links: 1 + Modified: XXXX-XX-XX XX:XX:XX XXX +/latest Group + Location: 1:195 + Links: 1 + Modified: XXXX-XX-XX XX:XX:XX XXX diff --git a/tools/test/misc/expected/h5mkgrp_single_p.ls b/tools/test/misc/expected/h5mkgrp_single_p.ls new file mode 100644 index 0000000..e82dc31 --- /dev/null +++ b/tools/test/misc/expected/h5mkgrp_single_p.ls @@ -0,0 +1,7 @@ +Opened "h5mkgrp_single_p.h5" with sec2 driver. +/ Group + Location: 1:96 + Links: 1 +/single Group + Location: 1:800 + Links: 1 diff --git a/tools/test/misc/expected/h5mkgrp_single_v.ls b/tools/test/misc/expected/h5mkgrp_single_v.ls new file mode 100644 index 0000000..7360865 --- /dev/null +++ b/tools/test/misc/expected/h5mkgrp_single_v.ls @@ -0,0 +1,7 @@ +Opened "h5mkgrp_single_v.h5" with sec2 driver. +/ Group + Location: 1:96 + Links: 1 +/single Group + Location: 1:800 + Links: 1 diff --git a/tools/test/misc/h5clear_gentest.c b/tools/test/misc/h5clear_gentest.c index 5cb7aa2..892e974 100644 --- a/tools/test/misc/h5clear_gentest.c +++ b/tools/test/misc/h5clear_gentest.c @@ -64,7 +64,7 @@ gen_cache_image_file(const char *fname) int arr[50][100]; } * buf; /* Buffer for data to write */ H5AC_cache_image_config_t cache_image_config = /* Cache image input configuration */ - {H5AC__CURR_CACHE_IMAGE_CONFIG_VERSION, TRUE, FALSE, H5AC__CACHE_IMAGE__ENTRY_AGEOUT__NONE}; + {H5AC__CURR_CACHE_IMAGE_CONFIG_VERSION, true, false, H5AC__CACHE_IMAGE__ENTRY_AGEOUT__NONE}; /* Create and fill array */ buf = malloc(sizeof(*buf)); @@ -168,7 +168,7 @@ error: *------------------------------------------------------------------------- */ static int -gen_enhance_files(hbool_t user) +gen_enhance_files(bool user) { hid_t fid = H5I_INVALID_HID; /* File ID */ hid_t fcpl = H5I_INVALID_HID; /* File creation property list */ @@ -193,7 +193,7 @@ gen_enhance_files(hbool_t user) } /* Set file space strategy and persisting free-space */ - if (H5Pset_file_space_strategy(fcpl, H5F_FSPACE_STRATEGY_FSM_AGGR, TRUE, (hsize_t)1) < 0) + if (H5Pset_file_space_strategy(fcpl, H5F_FSPACE_STRATEGY_FSM_AGGR, true, (hsize_t)1) < 0) goto error; /* @@ -274,7 +274,7 @@ gen_enhance_files(hbool_t user) } /* location of "end of file address" */ - if (lseek(fd, (off_t)(28 + (user ? USERBLOCK : 0)), SEEK_SET) < 0) + if (lseek(fd, (HDoff_t)(28 + (user ? USERBLOCK : 0)), SEEK_SET) < 0) goto error; /* Write the bad eoa value to the file */ @@ -282,7 +282,7 @@ gen_enhance_files(hbool_t user) goto error; /* location of "superblock checksum" */ - if (lseek(fd, (off_t)(44 + (user ? USERBLOCK : 0)), SEEK_SET) < 0) + if (lseek(fd, (HDoff_t)(44 + (user ? USERBLOCK : 0)), SEEK_SET) < 0) goto error; /* Write the chksum value to the file */ @@ -383,9 +383,9 @@ main(void) goto error; /* Generate the first 6 files in FILENAME_ENHANCE[] */ - if (gen_enhance_files(FALSE) < 0) + if (gen_enhance_files(false) < 0) goto error; - if (gen_enhance_files(TRUE) < 0) + if (gen_enhance_files(true) < 0) goto error; /* @@ -407,7 +407,7 @@ main(void) * --FILENAME[0]: "h5clear_sec2_v3.h5", "latest_h5clear_sec2_v3.h5" * --FILENAME[1]: "h5clear_log_v3.h5", "latest_h5clear_log_v3.h5" */ - for (new_format = FALSE; new_format <= TRUE; new_format++) { + for (new_format = false; new_format <= true; new_format++) { hid_t fapl2, my_fapl; /* File access property lists */ /* Set to use the appropriate file access property list */ @@ -421,7 +421,7 @@ main(void) if ((my_fapl = H5Pcopy(fapl2)) < 0) goto error; /* Create the file */ - HDsnprintf(fname, sizeof(fname), "%s%s", new_format ? "latest_" : "", FILENAME[0]); + snprintf(fname, sizeof(fname), "%s%s", new_format ? "latest_" : "", FILENAME[0]); if ((fid = H5Fcreate(fname, H5F_ACC_TRUNC | (new_format ? 0 : H5F_ACC_SWMR_WRITE), H5P_DEFAULT, my_fapl)) < 0) goto error; @@ -446,7 +446,7 @@ main(void) goto error; /* Create the file */ - HDsnprintf(fname, sizeof(fname), "%s%s", new_format ? "latest_" : "", FILENAME[1]); + snprintf(fname, sizeof(fname), "%s%s", new_format ? "latest_" : "", FILENAME[1]); if ((fid = H5Fcreate(fname, H5F_ACC_TRUNC | (new_format ? 0 : H5F_ACC_SWMR_WRITE), H5P_DEFAULT, my_fapl)) < 0) goto error; @@ -559,7 +559,7 @@ main(void) goto error; /* Set file space strategy and persisting free-space */ - if (H5Pset_file_space_strategy(fcpl, H5F_FSPACE_STRATEGY_FSM_AGGR, TRUE, (hsize_t)1) < 0) + if (H5Pset_file_space_strategy(fcpl, H5F_FSPACE_STRATEGY_FSM_AGGR, true, (hsize_t)1) < 0) goto error; /* Create the file with the set file space info */ diff --git a/tools/test/misc/h5perf_gentest.c b/tools/test/misc/h5perf_gentest.c index 24d0581..7756914 100644 --- a/tools/test/misc/h5perf_gentest.c +++ b/tools/test/misc/h5perf_gentest.c @@ -103,7 +103,7 @@ main(int argc, char *argv[]) } if (strlen(fname) <= 0) - HDsnprintf(fname, sizeof(fname), FNAME); + snprintf(fname, sizeof(fname), FNAME); create_perf_test_file(fname, ngrps, ndsets, nattrs, (hsize_t)nrows, (hsize_t)dim0, (hsize_t)chunk, vlen, z, l); @@ -322,7 +322,7 @@ create_perf_test_file(const char *fname, int ngrps, int ndsets, int nattrs, hsiz fid = H5Fcreate(fname, H5F_ACC_TRUNC, H5P_DEFAULT, H5P_DEFAULT); add_attrs(fid, 0); - HDsnprintf(name, sizeof(name), "a cmp ds of %d rows", nrows); + snprintf(name, sizeof(name), "a cmp ds of %d rows", nrows); did = H5Dcreate(fid, name, cmp_tid, sid_large, H5P_DEFAULT, dcpl, H5P_DEFAULT); H5Dwrite(did, cmp_tid, H5S_ALL, H5S_ALL, H5P_DEFAULT, buf_comp_large); add_attrs(did, 0); @@ -342,7 +342,7 @@ create_perf_test_file(const char *fname, int ngrps, int ndsets, int nattrs, hsiz add_attrs(gid1, 0); for (i = 0; i < ngrps; i++) { /* create sub groups */ - HDsnprintf(name, sizeof(name), "g%02d", i); + snprintf(name, sizeof(name), "g%02d", i); gid2 = H5Gcreate(gid1, name, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT); if (i < 10) add_attrs(gid2, 0); @@ -355,14 +355,14 @@ create_perf_test_file(const char *fname, int ngrps, int ndsets, int nattrs, hsiz add_attrs(gid1, 0); for (j = 0; j < ndsets; j += 12) { /* 1 add a null dataset */ - HDsnprintf(name, sizeof(name), "%05d null dataset", j); + snprintf(name, sizeof(name), "%05d null dataset", j); did = H5Dcreate(gid1, name, H5T_STD_I32LE, sid_null, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT); if (!j) add_attrs(did, j); H5Dclose(did); /* 2 add scalar int point */ - HDsnprintf(name, sizeof(name), "%05d scalar int point", j); + snprintf(name, sizeof(name), "%05d scalar int point", j); did = H5Dcreate(gid1, name, H5T_NATIVE_INT, sid_scalar, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT); H5Dwrite(did, H5T_NATIVE_INT, H5S_ALL, H5S_ALL, H5P_DEFAULT, &j); if (!j) @@ -370,7 +370,7 @@ create_perf_test_file(const char *fname, int ngrps, int ndsets, int nattrs, hsiz H5Dclose(did); /* 3 scalar vlen string */ - HDsnprintf(name, sizeof(name), "%05d scalar vlen string", j); + snprintf(name, sizeof(name), "%05d scalar vlen string", j); did = H5Dcreate(gid1, name, tid_vlen_s, sid_scalar, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT); H5Dwrite(did, tid_vlen_s, H5S_ALL, H5S_ALL, H5P_DEFAULT, &buf_vlen_s[0]); if (!j) @@ -378,7 +378,7 @@ create_perf_test_file(const char *fname, int ngrps, int ndsets, int nattrs, hsiz H5Dclose(did); /* 4 add fixed-length float array */ - HDsnprintf(name, sizeof(name), "%05d fixed-length float array", j); + snprintf(name, sizeof(name), "%05d fixed-length float array", j); did = H5Dcreate(gid1, name, tid_array_f, sid_1d, H5P_DEFAULT, dcpl, H5P_DEFAULT); H5Dwrite(did, tid_array_f, H5S_ALL, H5S_ALL, H5P_DEFAULT, buf_float_a); if (!j) @@ -386,7 +386,7 @@ create_perf_test_file(const char *fname, int ngrps, int ndsets, int nattrs, hsiz H5Dclose(did); /* 5 add fixed-length strings */ - HDsnprintf(name, sizeof(name), "%05d fixed-length strings", j); + snprintf(name, sizeof(name), "%05d fixed-length strings", j); did = H5Dcreate(gid1, name, tid_str, sid_1d, H5P_DEFAULT, dcpl, H5P_DEFAULT); H5Dwrite(did, tid_str, H5S_ALL, H5S_ALL, H5P_DEFAULT, buf_str); if (!j) @@ -394,7 +394,7 @@ create_perf_test_file(const char *fname, int ngrps, int ndsets, int nattrs, hsiz H5Dclose(did); /* 6 add compound data */ - HDsnprintf(name, sizeof(name), "%05d compound data", j); + snprintf(name, sizeof(name), "%05d compound data", j); did = H5Dcreate(gid1, name, cmp_tid, sid_1d, H5P_DEFAULT, dcpl, H5P_DEFAULT); H5Dwrite(did, cmp_tid, H5S_ALL, H5S_ALL, H5P_DEFAULT, buf_comp); if (!j) @@ -402,7 +402,7 @@ create_perf_test_file(const char *fname, int ngrps, int ndsets, int nattrs, hsiz H5Dclose(did); /* 7 add 2D double */ - HDsnprintf(name, sizeof(name), "%05d 2D double", j); + snprintf(name, sizeof(name), "%05d 2D double", j); strcpy(tmp_name1, name); did = H5Dcreate(gid1, name, H5T_NATIVE_DOUBLE, sid_2d, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT); H5Dwrite(did, H5T_NATIVE_DOUBLE, H5S_ALL, H5S_ALL, H5P_DEFAULT, buf_double2d[0]); @@ -411,7 +411,7 @@ create_perf_test_file(const char *fname, int ngrps, int ndsets, int nattrs, hsiz H5Dclose(did); /* 8 add 1D int array */ - HDsnprintf(name, sizeof(name), "%05d 1D int array", j); + snprintf(name, sizeof(name), "%05d 1D int array", j); did = H5Dcreate(gid1, name, H5T_NATIVE_INT, sid_1d, H5P_DEFAULT, dcpl, H5P_DEFAULT); H5Dwrite(did, H5T_NATIVE_INT, H5S_ALL, H5S_ALL, H5P_DEFAULT, buf_int); if (!j) @@ -419,7 +419,7 @@ create_perf_test_file(const char *fname, int ngrps, int ndsets, int nattrs, hsiz H5Dclose(did); /* 9 add vlen int array */ - HDsnprintf(name, sizeof(name), "%05d vlen int array", j); + snprintf(name, sizeof(name), "%05d vlen int array", j); strcpy(tmp_name2, name); did = H5Dcreate(gid1, name, tid_vlen_i, sid_1d, H5P_DEFAULT, dcpl, H5P_DEFAULT); H5Dwrite(did, tid_vlen_i, H5S_ALL, H5S_ALL, H5P_DEFAULT, buf_vlen_i); @@ -428,7 +428,7 @@ create_perf_test_file(const char *fname, int ngrps, int ndsets, int nattrs, hsiz H5Dclose(did); /* 10 add vlen strings */ - HDsnprintf(name, sizeof(name), "%05d vlen strings", j); + snprintf(name, sizeof(name), "%05d vlen strings", j); strcpy(tmp_name3, name); did = H5Dcreate(gid1, name, tid_vlen_s, sid_1d, H5P_DEFAULT, dcpl, H5P_DEFAULT); H5Dwrite(did, tid_vlen_s, H5S_ALL, H5S_ALL, H5P_DEFAULT, buf_vlen_s); @@ -439,7 +439,7 @@ create_perf_test_file(const char *fname, int ngrps, int ndsets, int nattrs, hsiz /* 11 add object refs */ H5Rcreate(&buf_ref[0], gid1, ".", H5R_OBJECT, (hid_t)-1); H5Rcreate(&buf_ref[1], gid1, tmp_name3, H5R_OBJECT, (hid_t)-1); - HDsnprintf(name, sizeof(name), "%05d obj refs", j); + snprintf(name, sizeof(name), "%05d obj refs", j); did = H5Dcreate(gid1, name, H5T_STD_REF_OBJ, sid_2, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT); H5Dwrite(did, H5T_STD_REF_OBJ, H5S_ALL, H5S_ALL, H5P_DEFAULT, buf_ref); if (!j) @@ -454,7 +454,7 @@ create_perf_test_file(const char *fname, int ngrps, int ndsets, int nattrs, hsiz H5Sselect_hyperslab(sid_1d, H5S_SELECT_SET, &start, &stride, &count, NULL); H5Rcreate(&buf_reg_ref[1], gid1, tmp_name2, H5R_DATASET_REGION, sid_1d); H5Sselect_none(sid_1d); - HDsnprintf(name, sizeof(name), "%05d region refs", j); + snprintf(name, sizeof(name), "%05d region refs", j); did = H5Dcreate(gid1, name, H5T_STD_REF_DSETREG, sid_2, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT); H5Dwrite(did, H5T_STD_REF_DSETREG, H5S_ALL, H5S_ALL, H5P_DEFAULT, buf_reg_ref); if (!j) @@ -570,11 +570,11 @@ add_attrs(hid_t oid, int idx) /* 1 scalar point */ sid = H5Screate(H5S_SCALAR); - HDsnprintf(name, sizeof(name), "%05d scalar int", idx); + snprintf(name, sizeof(name), "%05d scalar int", idx); nattrs += add_attr(oid, name, H5T_NATIVE_UINT, sid, &i); - HDsnprintf(name, sizeof(name), "%05d scalar ulong", idx); + snprintf(name, sizeof(name), "%05d scalar ulong", idx); nattrs += add_attr(oid, name, H5T_NATIVE_INT64, sid, &l); - HDsnprintf(name, sizeof(name), "%05d scalar str", idx); + snprintf(name, sizeof(name), "%05d scalar str", idx); tid = H5Tcopy(H5T_C_S1); H5Tset_size(tid, H5T_VARIABLE); nattrs += add_attr(oid, name, tid, sid, &s[2]); @@ -584,24 +584,24 @@ add_attrs(hid_t oid, int idx) /* 4 single point */ sid = H5Screate_simple(1, dims1, NULL); H5Rcreate(&ref, oid, ".", H5R_OBJECT, (hid_t)-1); - HDsnprintf(name, sizeof(name), "%05d single float", idx); + snprintf(name, sizeof(name), "%05d single float", idx); nattrs += add_attr(oid, name, H5T_NATIVE_FLOAT, sid, &f); - HDsnprintf(name, sizeof(name), "%05d single double", idx); + snprintf(name, sizeof(name), "%05d single double", idx); nattrs += add_attr(oid, name, H5T_NATIVE_DOUBLE, sid, &d); - HDsnprintf(name, sizeof(name), "%05d single obj_ref", idx); + snprintf(name, sizeof(name), "%05d single obj_ref", idx); nattrs += add_attr(oid, name, H5T_STD_REF_OBJ, sid, &ref); H5Sclose(sid); /* 7 fixed length 1D array */ sid = H5Screate_simple(1, dims1, NULL); tid = H5Tarray_create(H5T_NATIVE_FLOAT, 1, dims2); - HDsnprintf(name, sizeof(name), "%05d array float", idx); + snprintf(name, sizeof(name), "%05d array float", idx); nattrs += add_attr(oid, name, tid, sid, &f_array[0]); H5Tclose(tid); tid = H5Tcopy(H5T_C_S1); H5Tset_size(tid, strlen(s[0]) + 1); tid1 = H5Tarray_create(tid, 1, dims2); - HDsnprintf(name, sizeof(name), "%05d array str", idx); + snprintf(name, sizeof(name), "%05d array str", idx); nattrs += add_attr(oid, name, tid1, sid, s); H5Tclose(tid1); H5Tclose(tid); @@ -610,7 +610,7 @@ add_attrs(hid_t oid, int idx) /* 9 fixed length 2D int arrays */ sid = H5Screate_simple(1, dims2, NULL); tid = H5Tarray_create(H5T_NATIVE_INT, 2, dims3); - HDsnprintf(name, sizeof(name), "%05d array int 2D", idx); + snprintf(name, sizeof(name), "%05d array int 2D", idx); nattrs += add_attr(oid, name, tid, sid, int3d[0][0]); H5Tclose(tid); H5Sclose(sid); @@ -619,12 +619,12 @@ add_attrs(hid_t oid, int idx) sid = H5Screate_simple(1, dims2, NULL); tid = H5Tcopy(H5T_C_S1); H5Tset_size(tid, H5T_VARIABLE); - HDsnprintf(name, sizeof(name), "%05d vlen strings", idx); + snprintf(name, sizeof(name), "%05d vlen strings", idx); nattrs += add_attr(oid, name, tid, sid, s_vlen); H5Tclose(tid); tid = H5Tvlen_create(H5T_NATIVE_INT); ; - HDsnprintf(name, sizeof(name), "%05d vlen int array", idx); + snprintf(name, sizeof(name), "%05d vlen int array", idx); nattrs += add_attr(oid, name, tid, sid, i_vlen); H5Tclose(tid); H5Sclose(sid); @@ -638,7 +638,7 @@ add_attrs(hid_t oid, int idx) offset += sizeof(H5T_NATIVE_INT); H5Tinsert(tid, "City", offset, tid1); offset += sizeof(char *); - HDsnprintf(name, sizeof(name), "%05d compound data", idx); + snprintf(name, sizeof(name), "%05d compound data", idx); nattrs += add_attr(oid, name, tid, sid, cmp_data); H5Tclose(tid1); H5Tclose(tid); diff --git a/tools/test/misc/h5repart_gentest.c b/tools/test/misc/h5repart_gentest.c index 9f0eee1..a4a4ab1 100644 --- a/tools/test/misc/h5repart_gentest.c +++ b/tools/test/misc/h5repart_gentest.c @@ -34,11 +34,11 @@ main(void) /* Set up data array */ if (NULL == (buf_data = (int *)calloc(FAMILY_NUMBER * FAMILY_SIZE, sizeof(int)))) { - HDperror("calloc"); + perror("calloc"); exit(EXIT_FAILURE); } if (NULL == (buf = (int **)calloc(FAMILY_NUMBER, sizeof(buf_data)))) { - HDperror("calloc"); + perror("calloc"); exit(EXIT_FAILURE); } for (i = 0; i < FAMILY_NUMBER; i++) @@ -46,28 +46,28 @@ main(void) /* Set property list and file name for FAMILY driver */ if ((fapl = H5Pcreate(H5P_FILE_ACCESS)) < 0) { - HDperror("H5Pcreate"); + perror("H5Pcreate"); exit(EXIT_FAILURE); } if (H5Pset_fapl_family(fapl, (hsize_t)FAMILY_SIZE, H5P_DEFAULT) < 0) { - HDperror("H5Pset_fapl_family"); + perror("H5Pset_fapl_family"); exit(EXIT_FAILURE); } if ((file = H5Fcreate(FILENAME, H5F_ACC_TRUNC, H5P_DEFAULT, fapl)) < 0) { - HDperror("H5Fcreate"); + perror("H5Fcreate"); exit(EXIT_FAILURE); } /* Create and write dataset */ if ((space = H5Screate_simple(2, dims, NULL)) < 0) { - HDperror("H5Screate_simple"); + perror("H5Screate_simple"); exit(EXIT_FAILURE); } if ((dset = H5Dcreate2(file, dname, H5T_NATIVE_INT, space, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) { - HDperror("H5Dcreate2"); + perror("H5Dcreate2"); exit(EXIT_FAILURE); } @@ -76,34 +76,34 @@ main(void) buf[i][j] = i * 10000 + j; if (H5Dwrite(dset, H5T_NATIVE_INT, H5S_ALL, H5S_ALL, H5P_DEFAULT, buf_data) < 0) { - HDperror("H5Dwrite"); + perror("H5Dwrite"); exit(EXIT_FAILURE); } if (H5Sclose(space) < 0) { - HDperror("H5Sclose"); + perror("H5Sclose"); exit(EXIT_FAILURE); } if (H5Dclose(dset) < 0) { - HDperror("H5Dclose"); + perror("H5Dclose"); exit(EXIT_FAILURE); } if (H5Pclose(fapl) < 0) { - HDperror("H5Pclose"); + perror("H5Pclose"); exit(EXIT_FAILURE); } if (H5Fclose(file) < 0) { - HDperror("H5Fclose"); + perror("H5Fclose"); exit(EXIT_FAILURE); } free(buf); free(buf_data); - HDputs(" PASSED"); + puts(" PASSED"); fflush(stdout); return EXIT_SUCCESS; diff --git a/tools/test/misc/talign.c b/tools/test/misc/talign.c index 805b30b..b64c8ad 100644 --- a/tools/test/misc/talign.c +++ b/tools/test/misc/talign.c @@ -53,12 +53,12 @@ main(void) printf("%-70s", "Testing alignment in compound datatypes"); - HDstrcpy(string5, "Hi!"); + strcpy(string5, "Hi!"); HDunlink(fname); fil = H5Fcreate(fname, H5F_ACC_TRUNC, H5P_DEFAULT, H5P_DEFAULT); if (fil < 0) { - HDputs("*FAILED*"); + puts("*FAILED*"); return 1; } @@ -125,7 +125,7 @@ main(void) data = (char *)malloc(H5Tget_size(fix)); if (!data) { - HDperror("malloc() failed"); + perror("malloc() failed"); HDabort(); } @@ -138,7 +138,7 @@ main(void) out: if (error < 0) { result = 1; - HDputs("*FAILED - HDF5 library error*"); + puts("*FAILED - HDF5 library error*"); } else if (!(H5_FLT_ABS_EQUAL(fok[0], fptr[0])) || !(H5_FLT_ABS_EQUAL(fok[1], fptr[1])) || !(H5_FLT_ABS_EQUAL(fnok[0], fptr[2])) || !(H5_FLT_ABS_EQUAL(fnok[1], fptr[3]))) { @@ -179,10 +179,10 @@ out: " %6f = %f\n", (double)fok[0], (double)fptr[0], (double)fok[1], (double)fptr[1], (double)fnok[0], (double)fptr[2], (double)fnok[1], (double)fptr[3]); - HDputs("*FAILED - compound type alignmnent problem*"); + puts("*FAILED - compound type alignnent problem*"); } else { - HDputs(" PASSED"); + puts(" PASSED"); } if (data) diff --git a/tools/test/misc/testfiles/family_file00000.h5 b/tools/test/misc/testfiles/family_file00000.h5 Binary files differnew file mode 100644 index 0000000..88f75ca --- /dev/null +++ b/tools/test/misc/testfiles/family_file00000.h5 diff --git a/tools/test/misc/testfiles/family_file00001.h5 b/tools/test/misc/testfiles/family_file00001.h5 Binary files differnew file mode 100644 index 0000000..0da088e --- /dev/null +++ b/tools/test/misc/testfiles/family_file00001.h5 diff --git a/tools/test/misc/testfiles/family_file00002.h5 b/tools/test/misc/testfiles/family_file00002.h5 Binary files differnew file mode 100644 index 0000000..c458a23 --- /dev/null +++ b/tools/test/misc/testfiles/family_file00002.h5 diff --git a/tools/test/misc/testfiles/family_file00003.h5 b/tools/test/misc/testfiles/family_file00003.h5 Binary files differnew file mode 100644 index 0000000..7e98035 --- /dev/null +++ b/tools/test/misc/testfiles/family_file00003.h5 diff --git a/tools/test/misc/testfiles/family_file00004.h5 b/tools/test/misc/testfiles/family_file00004.h5 Binary files differnew file mode 100644 index 0000000..cf6f4905 --- /dev/null +++ b/tools/test/misc/testfiles/family_file00004.h5 diff --git a/tools/test/misc/testfiles/family_file00005.h5 b/tools/test/misc/testfiles/family_file00005.h5 Binary files differnew file mode 100644 index 0000000..864564a --- /dev/null +++ b/tools/test/misc/testfiles/family_file00005.h5 diff --git a/tools/test/misc/testfiles/family_file00006.h5 b/tools/test/misc/testfiles/family_file00006.h5 Binary files differnew file mode 100644 index 0000000..9cc2693 --- /dev/null +++ b/tools/test/misc/testfiles/family_file00006.h5 diff --git a/tools/test/misc/testfiles/family_file00007.h5 b/tools/test/misc/testfiles/family_file00007.h5 Binary files differnew file mode 100644 index 0000000..a0f0043 --- /dev/null +++ b/tools/test/misc/testfiles/family_file00007.h5 diff --git a/tools/test/misc/testfiles/family_file00008.h5 b/tools/test/misc/testfiles/family_file00008.h5 Binary files differnew file mode 100644 index 0000000..eec73e0 --- /dev/null +++ b/tools/test/misc/testfiles/family_file00008.h5 diff --git a/tools/test/misc/testfiles/family_file00009.h5 b/tools/test/misc/testfiles/family_file00009.h5 Binary files differnew file mode 100644 index 0000000..b28cf90 --- /dev/null +++ b/tools/test/misc/testfiles/family_file00009.h5 diff --git a/tools/test/misc/testfiles/family_file00010.h5 b/tools/test/misc/testfiles/family_file00010.h5 Binary files differnew file mode 100644 index 0000000..fe1a620 --- /dev/null +++ b/tools/test/misc/testfiles/family_file00010.h5 diff --git a/tools/test/misc/testfiles/family_file00011.h5 b/tools/test/misc/testfiles/family_file00011.h5 Binary files differnew file mode 100644 index 0000000..4e5d9e4 --- /dev/null +++ b/tools/test/misc/testfiles/family_file00011.h5 diff --git a/tools/test/misc/testfiles/family_file00012.h5 b/tools/test/misc/testfiles/family_file00012.h5 Binary files differnew file mode 100644 index 0000000..c70b87e --- /dev/null +++ b/tools/test/misc/testfiles/family_file00012.h5 diff --git a/tools/test/misc/testfiles/family_file00013.h5 b/tools/test/misc/testfiles/family_file00013.h5 Binary files differnew file mode 100644 index 0000000..b181df8 --- /dev/null +++ b/tools/test/misc/testfiles/family_file00013.h5 diff --git a/tools/test/misc/testfiles/family_file00014.h5 b/tools/test/misc/testfiles/family_file00014.h5 Binary files differnew file mode 100644 index 0000000..74867f1 --- /dev/null +++ b/tools/test/misc/testfiles/family_file00014.h5 diff --git a/tools/test/misc/testfiles/family_file00015.h5 b/tools/test/misc/testfiles/family_file00015.h5 Binary files differnew file mode 100644 index 0000000..de984c2 --- /dev/null +++ b/tools/test/misc/testfiles/family_file00015.h5 diff --git a/tools/test/misc/testfiles/family_file00016.h5 b/tools/test/misc/testfiles/family_file00016.h5 Binary files differnew file mode 100644 index 0000000..810cf34 --- /dev/null +++ b/tools/test/misc/testfiles/family_file00016.h5 diff --git a/tools/test/misc/testfiles/family_file00017.h5 b/tools/test/misc/testfiles/family_file00017.h5 Binary files differnew file mode 100644 index 0000000..9171ab9 --- /dev/null +++ b/tools/test/misc/testfiles/family_file00017.h5 diff --git a/tools/test/misc/testh5clear.sh.in b/tools/test/misc/testh5clear.sh.in index 018d1fd..b5bf5cc 100644 --- a/tools/test/misc/testh5clear.sh.in +++ b/tools/test/misc/testh5clear.sh.in @@ -40,9 +40,9 @@ verbose=yes # source dirs SRC_TOOLS="$srcdir/../.." -SRC_TOOLS_TESTFILES="$SRC_TOOLS/testfiles" # testfiles source dirs for tools SRC_H5CLEAR_TESTFILES="$SRC_TOOLS/test/misc/testfiles" +SRC_H5CLEAR_OUTFILES="$SRC_TOOLS/test/misc/expected" TESTDIR=./testh5clear test -d $TESTDIR || mkdir -p $TESTDIR @@ -61,25 +61,25 @@ test -d $TESTDIR || mkdir -p $TESTDIR # copy test files and expected output files from source dirs to test dir # COPY_TESTFILES=" -$SRC_H5CLEAR_TESTFILES/h5clear_open_fail.err -$SRC_H5CLEAR_TESTFILES/h5clear_no_mdc_image.err -$SRC_H5CLEAR_TESTFILES/h5clear_usage.ddl -$SRC_H5CLEAR_TESTFILES/h5clear_missing_file.ddl -$SRC_H5CLEAR_TESTFILES/h5clear_status_noclose_after_size.ddl -$SRC_H5CLEAR_TESTFILES/h5clear_noclose_before_size.ddl -$SRC_H5CLEAR_TESTFILES/h5clear_noclose_after_size.ddl -$SRC_H5CLEAR_TESTFILES/h5clear_equal_before_size.ddl -$SRC_H5CLEAR_TESTFILES/h5clear_equal_after_size.ddl -$SRC_H5CLEAR_TESTFILES/h5clear_greater_before_size.ddl -$SRC_H5CLEAR_TESTFILES/h5clear_greater_after_size.ddl -$SRC_H5CLEAR_TESTFILES/h5clear_less_before_size.ddl -$SRC_H5CLEAR_TESTFILES/h5clear_less_after_size.ddl -$SRC_H5CLEAR_TESTFILES/h5clear_user_equal_before_size.ddl -$SRC_H5CLEAR_TESTFILES/h5clear_user_equal_after_size.ddl -$SRC_H5CLEAR_TESTFILES/h5clear_user_greater_before_size.ddl -$SRC_H5CLEAR_TESTFILES/h5clear_user_greater_after_size.ddl -$SRC_H5CLEAR_TESTFILES/h5clear_user_less_before_size.ddl -$SRC_H5CLEAR_TESTFILES/h5clear_user_less_after_size.ddl +$SRC_H5CLEAR_OUTFILES/h5clear_open_fail.err +$SRC_H5CLEAR_OUTFILES/h5clear_no_mdc_image.err +$SRC_H5CLEAR_OUTFILES/h5clear_usage.ddl +$SRC_H5CLEAR_OUTFILES/h5clear_missing_file.ddl +$SRC_H5CLEAR_OUTFILES/h5clear_status_noclose_after_size.ddl +$SRC_H5CLEAR_OUTFILES/h5clear_noclose_before_size.ddl +$SRC_H5CLEAR_OUTFILES/h5clear_noclose_after_size.ddl +$SRC_H5CLEAR_OUTFILES/h5clear_equal_before_size.ddl +$SRC_H5CLEAR_OUTFILES/h5clear_equal_after_size.ddl +$SRC_H5CLEAR_OUTFILES/h5clear_greater_before_size.ddl +$SRC_H5CLEAR_OUTFILES/h5clear_greater_after_size.ddl +$SRC_H5CLEAR_OUTFILES/h5clear_less_before_size.ddl +$SRC_H5CLEAR_OUTFILES/h5clear_less_after_size.ddl +$SRC_H5CLEAR_OUTFILES/h5clear_user_equal_before_size.ddl +$SRC_H5CLEAR_OUTFILES/h5clear_user_equal_after_size.ddl +$SRC_H5CLEAR_OUTFILES/h5clear_user_greater_before_size.ddl +$SRC_H5CLEAR_OUTFILES/h5clear_user_greater_after_size.ddl +$SRC_H5CLEAR_OUTFILES/h5clear_user_less_before_size.ddl +$SRC_H5CLEAR_OUTFILES/h5clear_user_less_after_size.ddl $SRC_H5CLEAR_TESTFILES/h5clear_sec2_v0.h5 $SRC_H5CLEAR_TESTFILES/h5clear_sec2_v2.h5 $SRC_H5CLEAR_TESTFILES/h5clear_sec2_v3.h5 diff --git a/tools/test/misc/testh5mkgrp.sh.in b/tools/test/misc/testh5mkgrp.sh.in index d581fe1..676f6b0 100644 --- a/tools/test/misc/testh5mkgrp.sh.in +++ b/tools/test/misc/testh5mkgrp.sh.in @@ -39,9 +39,9 @@ verbose=yes # source dirs SRC_TOOLS="$srcdir/../.." -SRC_TOOLS_TESTFILES="$SRC_TOOLS/testfiles" # testfiles source dirs for tools SRC_H5MKGRP_TESTFILES="$SRC_TOOLS/test/misc/testfiles" +SRC_H5MKGRP_OUTFILES="$SRC_TOOLS/test/misc/expected" TESTDIR=./testgrp test -d $TESTDIR || mkdir -p $TESTDIR @@ -60,19 +60,19 @@ test -d $TESTDIR || mkdir -p $TESTDIR # copy test files and expected output files from source dirs to test dir # COPY_TESTFILES=" -$SRC_H5MKGRP_TESTFILES/h5mkgrp_help.txt -$SRC_TOOLS_TESTFILES/h5mkgrp_single.ls -$SRC_TOOLS_TESTFILES/h5mkgrp_single_v.ls -$SRC_TOOLS_TESTFILES/h5mkgrp_single_p.ls -$SRC_TOOLS_TESTFILES/h5mkgrp_single_l.ls -$SRC_TOOLS_TESTFILES/h5mkgrp_several.ls -$SRC_TOOLS_TESTFILES/h5mkgrp_several_v.ls -$SRC_TOOLS_TESTFILES/h5mkgrp_several_p.ls -$SRC_TOOLS_TESTFILES/h5mkgrp_several_l.ls -$SRC_TOOLS_TESTFILES/h5mkgrp_nested_p.ls -$SRC_TOOLS_TESTFILES/h5mkgrp_nested_lp.ls -$SRC_TOOLS_TESTFILES/h5mkgrp_nested_mult_p.ls -$SRC_TOOLS_TESTFILES/h5mkgrp_nested_mult_lp.ls +$SRC_H5MKGRP_OUTFILES/h5mkgrp_help.txt +$SRC_H5MKGRP_OUTFILES/h5mkgrp_single.ls +$SRC_H5MKGRP_OUTFILES/h5mkgrp_single_v.ls +$SRC_H5MKGRP_OUTFILES/h5mkgrp_single_p.ls +$SRC_H5MKGRP_OUTFILES/h5mkgrp_single_l.ls +$SRC_H5MKGRP_OUTFILES/h5mkgrp_several.ls +$SRC_H5MKGRP_OUTFILES/h5mkgrp_several_v.ls +$SRC_H5MKGRP_OUTFILES/h5mkgrp_several_p.ls +$SRC_H5MKGRP_OUTFILES/h5mkgrp_several_l.ls +$SRC_H5MKGRP_OUTFILES/h5mkgrp_nested_p.ls +$SRC_H5MKGRP_OUTFILES/h5mkgrp_nested_lp.ls +$SRC_H5MKGRP_OUTFILES/h5mkgrp_nested_mult_p.ls +$SRC_H5MKGRP_OUTFILES/h5mkgrp_nested_mult_lp.ls " COPY_TESTFILES_TO_TESTDIR() diff --git a/tools/test/misc/testh5repart.sh.in b/tools/test/misc/testh5repart.sh.in index b0d52f6..addd0db 100644 --- a/tools/test/misc/testh5repart.sh.in +++ b/tools/test/misc/testh5repart.sh.in @@ -38,7 +38,7 @@ verbose=yes # source dirs SRC_TOOLS="$srcdir/../.." -SRC_TOOLS_TESTFILES="$SRC_TOOLS/testfiles" +SRC_H5REPART_TESTFILES="$SRC_TOOLS/test/misc/testfiles" TESTDIR=./testrepart test -d $TESTDIR || mkdir -p $TESTDIR @@ -47,24 +47,24 @@ test -d $TESTDIR || mkdir -p $TESTDIR # copy test files and expected output files from source dirs to test dir # COPY_TESTFILES=" -$SRC_TOOLS_TESTFILES/family_file00000.h5 -$SRC_TOOLS_TESTFILES/family_file00001.h5 -$SRC_TOOLS_TESTFILES/family_file00002.h5 -$SRC_TOOLS_TESTFILES/family_file00003.h5 -$SRC_TOOLS_TESTFILES/family_file00004.h5 -$SRC_TOOLS_TESTFILES/family_file00005.h5 -$SRC_TOOLS_TESTFILES/family_file00006.h5 -$SRC_TOOLS_TESTFILES/family_file00007.h5 -$SRC_TOOLS_TESTFILES/family_file00008.h5 -$SRC_TOOLS_TESTFILES/family_file00009.h5 -$SRC_TOOLS_TESTFILES/family_file00010.h5 -$SRC_TOOLS_TESTFILES/family_file00011.h5 -$SRC_TOOLS_TESTFILES/family_file00012.h5 -$SRC_TOOLS_TESTFILES/family_file00013.h5 -$SRC_TOOLS_TESTFILES/family_file00014.h5 -$SRC_TOOLS_TESTFILES/family_file00015.h5 -$SRC_TOOLS_TESTFILES/family_file00016.h5 -$SRC_TOOLS_TESTFILES/family_file00017.h5 +$SRC_H5REPART_TESTFILES/family_file00000.h5 +$SRC_H5REPART_TESTFILES/family_file00001.h5 +$SRC_H5REPART_TESTFILES/family_file00002.h5 +$SRC_H5REPART_TESTFILES/family_file00003.h5 +$SRC_H5REPART_TESTFILES/family_file00004.h5 +$SRC_H5REPART_TESTFILES/family_file00005.h5 +$SRC_H5REPART_TESTFILES/family_file00006.h5 +$SRC_H5REPART_TESTFILES/family_file00007.h5 +$SRC_H5REPART_TESTFILES/family_file00008.h5 +$SRC_H5REPART_TESTFILES/family_file00009.h5 +$SRC_H5REPART_TESTFILES/family_file00010.h5 +$SRC_H5REPART_TESTFILES/family_file00011.h5 +$SRC_H5REPART_TESTFILES/family_file00012.h5 +$SRC_H5REPART_TESTFILES/family_file00013.h5 +$SRC_H5REPART_TESTFILES/family_file00014.h5 +$SRC_H5REPART_TESTFILES/family_file00015.h5 +$SRC_H5REPART_TESTFILES/family_file00016.h5 +$SRC_H5REPART_TESTFILES/family_file00017.h5 " COPY_TESTFILES_TO_TESTDIR() @@ -100,7 +100,7 @@ CLEAN_TESTFILES_AND_TESTDIR() # skip rm if srcdir is same as destdir # this occurs when build/test performed in source dir and # make cp fail - SDIR=$SRC_TOOLS_TESTFILES + SDIR=$SRC_H5REPART_TESTFILES INODE_SDIR=`$LS -i -d $SDIR | $AWK -F' ' '{print $1}'` INODE_DDIR=`$LS -i -d $TESTDIR | $AWK -F' ' '{print $1}'` if [ "$INODE_SDIR" != "$INODE_DDIR" ]; then diff --git a/tools/test/misc/vds/UC_common.h b/tools/test/misc/vds/UC_common.h index 234ec87..4cfce35 100644 --- a/tools/test/misc/vds/UC_common.h +++ b/tools/test/misc/vds/UC_common.h @@ -26,10 +26,6 @@ /* Compression level */ #define COMPRESSION_LEVEL 7 -/* Booleans */ -#define TRUE 1 -#define FALSE 0 - /* Testing macros */ #define AT() printf(" at %s:%d in %s()...\n", __FILE__, __LINE__, __func__); #define UC_ERROR \ |