Skip to content

Commit

Permalink
fixing test
Browse files Browse the repository at this point in the history
  • Loading branch information
edwardhartnett committed Aug 28, 2024
1 parent ac1c3d7 commit 8775cc4
Showing 1 changed file with 7 additions and 9 deletions.
16 changes: 7 additions & 9 deletions h5_test/tst_h_zstd.c
Original file line number Diff line number Diff line change
Expand Up @@ -74,8 +74,6 @@ main()
if (H5Pset_chunk(propid, 1, dims)) ERR;
if ((code = H5Pset_filter(propid, id, H5Z_FLAG_OPTIONAL, 1, &ulevel)))
ERR;

if (H5Pset_deflate(propid, DEFLATE_LEVEL)) ERR;
if ((spaceid = H5Screate_simple(1, dims, dims)) < 0) ERR;
if ((datasetid = H5Dcreate1(grpid, VAR_BOOL_NAME, H5T_NATIVE_HBOOL,
spaceid, propid)) < 0) ERR;
Expand All @@ -97,13 +95,13 @@ main()
/* The possible values of filter (which is just an int) can be
* found in H5Zpublic.h. */
if ((num_filters = H5Pget_nfilters(propid)) < 0) ERR;
printf("num_filters %d\n");
/* if (num_filters != 1) ERR; */
/* if ((filter = H5Pget_filter2(propid, 0, &flags, &cd_nelems, cd_values, */
/* namelen, name, &filter_config)) < 0) ERR; */
/* if (filter != H5Z_FILTER_ZSTD || cd_nelems != 1 || */
/* cd_values[0] != ulevel) ERR; */
/* if (strcmp(name, ZSTD_NAME)) ERR; */
printf("num_filters %d\n", num_filters);
if (num_filters != 1) ERR;
if ((filter = H5Pget_filter2(propid, 0, &flags, &cd_nelems, cd_values,
namelen, name, &filter_config)) < 0) ERR;
if (filter != H5Z_FILTER_ZSTD || cd_nelems != 1 ||
cd_values[0] != ulevel) ERR;
if (strcmp(name, ZSTD_NAME)) ERR;

if (H5Dclose(datasetid) < 0 ||
H5Pclose(propid) < 0 ||
Expand Down

0 comments on commit 8775cc4

Please sign in to comment.