summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJordan Henderson <jhenderson@hdfgroup.org>2017-08-03 16:56:05 (GMT)
committerJordan Henderson <jhenderson@hdfgroup.org>2017-08-03 16:56:05 (GMT)
commit6abd4e9d1675b211c91be32010e4abca30a7fd8a (patch)
tree3bfb379ec6f670a46aea84affc69fceed0f574c1
parent50c4bc883500846f58ec1c8f55d57eef2b3f147b (diff)
downloadhdf5-6abd4e9d1675b211c91be32010e4abca30a7fd8a.zip
hdf5-6abd4e9d1675b211c91be32010e4abca30a7fd8a.tar.gz
hdf5-6abd4e9d1675b211c91be32010e4abca30a7fd8a.tar.bz2
Move test files to testpar directory
-rw-r--r--MANIFEST4
-rw-r--r--test/Makefile.am4
-rw-r--r--testpar/Makefile.am2
-rw-r--r--testpar/t_filters_parallel.c (renamed from test/tfilters_parallel.c)21
-rw-r--r--testpar/t_filters_parallel.h (renamed from test/tfilters_parallel.h)2
5 files changed, 20 insertions, 13 deletions
diff --git a/MANIFEST b/MANIFEST
index d61d392..beaad19 100644
--- a/MANIFEST
+++ b/MANIFEST
@@ -1070,8 +1070,6 @@
./test/testswmr.sh.in
./test/testvdsswmr.sh.in
./test/tfile.c
-./test/tfilters_parallel.c
-./test/tfilters_parallel.h
./test/tgenprop.c
./test/th5o.c
./test/th5s.c
@@ -1232,6 +1230,8 @@
./testpar/t_file.c
./testpar/t_file_image.c
./testpar/t_filter_read.c
+./testpar/tfilters_parallel.c
+./testpar/tfilters_parallel.h
./testpar/t_mdset.c
./testpar/t_mpi.c
./testpar/t_ph5basic.c
diff --git a/test/Makefile.am b/test/Makefile.am
index 0d80396..f64b6d8 100644
--- a/test/Makefile.am
+++ b/test/Makefile.am
@@ -79,7 +79,7 @@ check_PROGRAMS=$(TEST_PROG) error_test err_compat tcheck_version \
links_env filenotclosed flushrefresh use_append_chunk use_append_mchunks use_disable_mdc_flushes \
swmr_generator swmr_start_write swmr_reader swmr_writer swmr_remove_reader \
swmr_remove_writer swmr_addrem_writer swmr_sparse_reader swmr_sparse_writer \
- swmr_check_compat_vfd vds_swmr_gen vds_swmr_reader vds_swmr_writer tfilters_parallel
+ swmr_check_compat_vfd vds_swmr_gen vds_swmr_reader vds_swmr_writer
if HAVE_SHARED_CONDITIONAL
check_PROGRAMS+= plugin
endif
@@ -203,7 +203,7 @@ CHECK_CLEANFILES+=accum.h5 cmpd_dset.h5 compact_dataset.h5 dataset.h5 dset_offse
flushrefresh_VERIFICATION_DONE atomic_data accum_swmr_big.h5 ohdr_swmr.h5 \
test_swmr*.h5 cache_logging.h5 cache_logging.out vds_swmr.h5 vds_swmr_src_*.h5 \
swmr[0-2].h5 swmr_writer.out swmr_writer.log.* swmr_reader.out.* swmr_reader.log.* \
- tbogus.h5.copy cache_image_test.h5 tfilters_parallel.h5
+ tbogus.h5.copy cache_image_test.h5
# Sources for testhdf5 executable
testhdf5_SOURCES=testhdf5.c tarray.c tattr.c tchecksum.c tconfig.c tfile.c \
diff --git a/testpar/Makefile.am b/testpar/Makefile.am
index b87c1df..90bdd04 100644
--- a/testpar/Makefile.am
+++ b/testpar/Makefile.am
@@ -23,7 +23,7 @@ AM_CPPFLAGS+=-I$(top_srcdir)/src -I$(top_srcdir)/test
# Test programs. These are our main targets.
#
-TEST_PROG_PARA=t_mpi testphdf5 t_cache t_cache_image t_pflush1 t_pflush2 t_pshutdown t_prestart t_init_term t_shapesame
+TEST_PROG_PARA=t_mpi testphdf5 t_cache t_cache_image t_pflush1 t_pflush2 t_pshutdown t_prestart t_init_term t_shapesame t_filters_parallel
check_PROGRAMS = $(TEST_PROG_PARA)
diff --git a/test/tfilters_parallel.c b/testpar/t_filters_parallel.c
index 213e939..0de0350 100644
--- a/test/tfilters_parallel.c
+++ b/testpar/t_filters_parallel.c
@@ -21,7 +21,7 @@
* datasets in parallel with filters applied to the data.
*/
-#include "tfilters_parallel.h"
+#include "t_filters_parallel.h"
#define ARRAY_SIZE(a) sizeof(a) / sizeof(a[0])
@@ -93,14 +93,14 @@ test_one_chunk_filtered_dataset()
hsize_t block[ONE_CHUNK_FILTERED_DATASET_DIMS];
hsize_t offset[ONE_CHUNK_FILTERED_DATASET_DIMS];
size_t i, data_size;
- hid_t file_id, dset_id, plist_id;
- hid_t filespace, memspace;
+ hid_t file_id = -1, dset_id = -1, plist_id = -1;
+ hid_t filespace = -1, memspace = -1;
int ret_value = 0;
- if (mpi_rank == 0) puts("Testing one-chunk filtered dataset");
+ if (mpi_rank == 0) TESTING("one-chunk filtered dataset");
if ((plist_id = H5Pcreate(H5P_FILE_ACCESS)) < 0)
- goto error;
+ TEST_ERROR
if (H5Pset_fapl_mpio(plist_id, comm, info) < 0)
goto error;
if (H5Pset_libver_bounds(plist_id, H5F_LIBVER_LATEST, H5F_LIBVER_LATEST) < 0)
@@ -178,9 +178,16 @@ test_one_chunk_filtered_dataset()
goto exit;
error:
- if (mpi_rank == 0) puts("*** ONE-CHUNK FILTERED DATASET TEST FAILED ***");
+ H5E_BEGIN_TRY {
+ free(data);
+ H5Dclose(dset_id);
+ H5Sclose(filespace);
+ H5Sclose(memspace);
+ H5Pclose(plist_id);
+ H5Fclose(file_id);
+ } H5E_END_TRY;
- ret_value = 1;
+ return 1;
exit:
if (data)
diff --git a/test/tfilters_parallel.h b/testpar/t_filters_parallel.h
index 631b417..5c5f07f 100644
--- a/test/tfilters_parallel.h
+++ b/testpar/t_filters_parallel.h
@@ -28,7 +28,7 @@
#include <string.h>
#include "stdlib.h"
-#include "h5test.h"
+#include "testpar.h"
/* Used to load other filters than GZIP */
/* #define DYNAMIC_FILTER */ /* Uncomment and define the fields below to use a dynamically loaded filter */