summaryrefslogtreecommitdiffstats
path: root/test/API
diff options
context:
space:
mode:
Diffstat (limited to 'test/API')
-rw-r--r--test/API/tattr.c56
-rw-r--r--test/API/testhdf5.c10
-rw-r--r--test/API/tfile.c2
-rw-r--r--test/API/th5s.c16
-rw-r--r--test/API/tselect.c218
-rw-r--r--test/API/tunicode.c4
-rw-r--r--test/API/tvltypes.c12
7 files changed, 159 insertions, 159 deletions
diff --git a/test/API/tattr.c b/test/API/tattr.c
index 4e905b0..476e32b 100644
--- a/test/API/tattr.c
+++ b/test/API/tattr.c
@@ -4717,7 +4717,7 @@ test_attr_corder_create_compact(hid_t fcpl, hid_t fapl)
break;
default:
- HDassert(0 && "Too many datasets!");
+ assert(0 && "Too many datasets!");
} /* end switch */
#if 0
/* Check on dataset's attribute storage status */
@@ -4801,7 +4801,7 @@ test_attr_corder_create_compact(hid_t fcpl, hid_t fapl)
break;
default:
- HDassert(0 && "Too many datasets!");
+ assert(0 && "Too many datasets!");
} /* end switch */
#if 0
/* Check on dataset's attribute storage status */
@@ -4924,7 +4924,7 @@ test_attr_corder_create_dense(hid_t fcpl, hid_t fapl)
break;
default:
- HDassert(0 && "Too many datasets!");
+ assert(0 && "Too many datasets!");
} /* end switch */
#if 0
/* Check on dataset's attribute storage status */
@@ -5036,7 +5036,7 @@ test_attr_corder_create_dense(hid_t fcpl, hid_t fapl)
break;
default:
- HDassert(0 && "Too many datasets!");
+ assert(0 && "Too many datasets!");
} /* end switch */
#if 0
/* Check on dataset's attribute storage status */
@@ -5269,7 +5269,7 @@ test_attr_corder_transition(hid_t fcpl, hid_t fapl)
break;
default:
- HDassert(0 && "Too many datasets!");
+ assert(0 && "Too many datasets!");
} /* end switch */
#if 0
/* Check on dataset's attribute storage status */
@@ -5324,7 +5324,7 @@ test_attr_corder_transition(hid_t fcpl, hid_t fapl)
break;
default:
- HDassert(0 && "Too many datasets!");
+ assert(0 && "Too many datasets!");
} /* end switch */
/* Create several attributes, but keep storage in compact form */
@@ -5488,7 +5488,7 @@ test_attr_corder_transition(hid_t fcpl, hid_t fapl)
break;
default:
- HDassert(0 && "Too many datasets!");
+ assert(0 && "Too many datasets!");
} /* end switch */
#if 0
/* Check on dataset's attribute storage status */
@@ -5707,7 +5707,7 @@ test_attr_corder_delete(hid_t fcpl, hid_t fapl)
break;
default:
- HDassert(0 && "Too many datasets!");
+ assert(0 && "Too many datasets!");
} /* end switch */
#if 0
/* Check on dataset's attribute storage status */
@@ -6046,7 +6046,7 @@ test_attr_info_by_idx(hbool_t new_format, hid_t fcpl, hid_t fapl)
break;
default:
- HDassert(0 && "Too many datasets!");
+ assert(0 && "Too many datasets!");
} /* end switch */
#if 0
/* Check on dataset's attribute storage status */
@@ -6575,7 +6575,7 @@ test_attr_delete_by_idx(hbool_t new_format, hid_t fcpl, hid_t fapl)
break;
default:
- HDassert(0 && "Too many datasets!");
+ assert(0 && "Too many datasets!");
} /* end switch */
#if 0
/* Check on dataset's attribute storage status */
@@ -6647,7 +6647,7 @@ test_attr_delete_by_idx(hbool_t new_format, hid_t fcpl, hid_t fapl)
break;
default:
- HDassert(0 && "Too many datasets!");
+ assert(0 && "Too many datasets!");
} /* end switch */
/* Delete attributes from compact storage */
@@ -6707,7 +6707,7 @@ test_attr_delete_by_idx(hbool_t new_format, hid_t fcpl, hid_t fapl)
break;
default:
- HDassert(0 && "Too many datasets!");
+ assert(0 && "Too many datasets!");
} /* end switch */
/* Create more attributes, to push into dense form */
@@ -6780,7 +6780,7 @@ test_attr_delete_by_idx(hbool_t new_format, hid_t fcpl, hid_t fapl)
break;
default:
- HDassert(0 && "Too many datasets!");
+ assert(0 && "Too many datasets!");
} /* end switch */
/* Delete attributes from dense storage */
@@ -6850,7 +6850,7 @@ test_attr_delete_by_idx(hbool_t new_format, hid_t fcpl, hid_t fapl)
break;
default:
- HDassert(0 && "Too many datasets!");
+ assert(0 && "Too many datasets!");
} /* end switch */
/* Create attributes, to push into dense form */
@@ -6897,7 +6897,7 @@ test_attr_delete_by_idx(hbool_t new_format, hid_t fcpl, hid_t fapl)
break;
default:
- HDassert(0 && "Too many datasets!");
+ assert(0 && "Too many datasets!");
} /* end switch */
/* Delete every other attribute from dense storage, in appropriate order */
@@ -6950,7 +6950,7 @@ test_attr_delete_by_idx(hbool_t new_format, hid_t fcpl, hid_t fapl)
break;
default:
- HDassert(0 && "Too many datasets!");
+ assert(0 && "Too many datasets!");
} /* end switch */
/* Delete remaining attributes from dense storage, in appropriate order */
@@ -7252,7 +7252,7 @@ attr_iterate_check(hid_t fid, const char *dsetname, hid_t obj_id, H5_index_t idx
else {
unsigned nvisit = 0; /* # of links visited */
- HDassert(order == H5_ITER_NATIVE);
+ assert(order == H5_ITER_NATIVE);
for (v = 0; v < max_attrs; v++)
if (iter_info->visited[v] == TRUE)
nvisit++;
@@ -7283,7 +7283,7 @@ attr_iterate_check(hid_t fid, const char *dsetname, hid_t obj_id, H5_index_t idx
else {
unsigned nvisit = 0; /* # of links visited */
- HDassert(order == H5_ITER_NATIVE);
+ assert(order == H5_ITER_NATIVE);
for (v = 0; v < max_attrs; v++)
if (iter_info->visited[v] == TRUE)
nvisit++;
@@ -7314,7 +7314,7 @@ attr_iterate_check(hid_t fid, const char *dsetname, hid_t obj_id, H5_index_t idx
else {
unsigned nvisit = 0; /* # of links visited */
- HDassert(order == H5_ITER_NATIVE);
+ assert(order == H5_ITER_NATIVE);
for (v = 0; v < max_attrs; v++)
if (iter_info->visited[v] == TRUE)
nvisit++;
@@ -7347,7 +7347,7 @@ attr_iterate_check(hid_t fid, const char *dsetname, hid_t obj_id, H5_index_t idx
else {
unsigned nvisit = 0; /* # of links visited */
- HDassert(order == H5_ITER_NATIVE);
+ assert(order == H5_ITER_NATIVE);
for (v = 0; v < max_attrs; v++)
if (iter_info->visited[v] == TRUE)
nvisit++;
@@ -7589,7 +7589,7 @@ test_attr_iterate2(hbool_t new_format, hid_t fcpl, hid_t fapl)
break;
default:
- HDassert(0 && "Too many datasets!");
+ assert(0 && "Too many datasets!");
} /* end switch */
#if 0
/* Check on dataset's attribute storage status */
@@ -7694,7 +7694,7 @@ test_attr_iterate2(hbool_t new_format, hid_t fcpl, hid_t fapl)
break;
default:
- HDassert(0 && "Too many datasets!");
+ assert(0 && "Too many datasets!");
} /* end switch */
/* Create more attributes, to push into dense form */
@@ -7996,7 +7996,7 @@ test_attr_open_by_idx(hbool_t new_format, hid_t fcpl, hid_t fapl)
break;
default:
- HDassert(0 && "Too many datasets!");
+ assert(0 && "Too many datasets!");
} /* end switch */
#if 0
/* Check on dataset's attribute storage status */
@@ -8074,7 +8074,7 @@ test_attr_open_by_idx(hbool_t new_format, hid_t fcpl, hid_t fapl)
break;
default:
- HDassert(0 && "Too many datasets!");
+ assert(0 && "Too many datasets!");
} /* end switch */
/* Create more attributes, to push into dense form */
@@ -8338,7 +8338,7 @@ test_attr_open_by_name(hbool_t new_format, hid_t fcpl, hid_t fapl)
break;
default:
- HDassert(0 && "Too many datasets!");
+ assert(0 && "Too many datasets!");
} /* end switch */
#if 0
/* Check on dataset's attribute storage status */
@@ -8444,7 +8444,7 @@ test_attr_open_by_name(hbool_t new_format, hid_t fcpl, hid_t fapl)
break;
default:
- HDassert(0 && "Too many datasets!");
+ assert(0 && "Too many datasets!");
} /* end switch */
/* Create more attributes, to push into dense form */
@@ -8635,7 +8635,7 @@ test_attr_create_by_name(hbool_t new_format, hid_t fcpl, hid_t fapl)
break;
default:
- HDassert(0 && "Too many datasets!");
+ assert(0 && "Too many datasets!");
} /* end switch */
#if 0
/* Check on dataset's attribute storage status */
@@ -8698,7 +8698,7 @@ test_attr_create_by_name(hbool_t new_format, hid_t fcpl, hid_t fapl)
break;
default:
- HDassert(0 && "Too many datasets!");
+ assert(0 && "Too many datasets!");
} /* end switch */
/* Create more attributes, to push into dense form */
diff --git a/test/API/testhdf5.c b/test/API/testhdf5.c
index d015933..58cbfdf 100644
--- a/test/API/testhdf5.c
+++ b/test/API/testhdf5.c
@@ -117,7 +117,7 @@ getenv_all(MPI_Comm comm, int root, const char *name)
int len;
static char *env = NULL;
- HDassert(name);
+ assert(name);
MPI_Initialized(&mpi_initialized);
MPI_Finalized(&mpi_finalized);
@@ -125,7 +125,7 @@ getenv_all(MPI_Comm comm, int root, const char *name)
if (mpi_initialized && !mpi_finalized) {
MPI_Comm_rank(comm, &mpi_rank);
MPI_Comm_size(comm, &mpi_size);
- HDassert(root < mpi_size);
+ assert(root < mpi_size);
/* The root task does the getenv call
* and sends the result to the other tasks */
@@ -515,7 +515,7 @@ h5_using_default_driver(const char *drv_name)
{
hbool_t ret_val = TRUE;
- HDassert(H5_DEFAULT_VFD == H5FD_SEC2);
+ assert(H5_DEFAULT_VFD == H5FD_SEC2);
if (!drv_name)
drv_name = HDgetenv(HDF5_DRIVER);
@@ -533,8 +533,8 @@ h5_driver_is_default_vfd_compatible(hid_t fapl_id, hbool_t *default_vfd_compatib
hid_t driver_id = H5I_INVALID_HID;
herr_t ret_value = SUCCEED;
- HDassert(fapl_id >= 0);
- HDassert(default_vfd_compatible);
+ assert(fapl_id >= 0);
+ assert(default_vfd_compatible);
if (fapl_id == H5P_DEFAULT)
fapl_id = H5P_FILE_ACCESS_DEFAULT;
diff --git a/test/API/tfile.c b/test/API/tfile.c
index c0b2921..12c57e6 100644
--- a/test/API/tfile.c
+++ b/test/API/tfile.c
@@ -4486,7 +4486,7 @@ set_multi_split(hid_t fapl, hsize_t pagesize, hbool_t split)
hbool_t relax;
H5FD_mem_t mt;
- HDassert(split);
+ assert(split);
HDmemset(memb_name, 0, sizeof memb_name);
diff --git a/test/API/th5s.c b/test/API/th5s.c
index f09cfeb..d27e57c 100644
--- a/test/API/th5s.c
+++ b/test/API/th5s.c
@@ -1790,7 +1790,7 @@ test_h5s_encode_regular_hyper(H5F_libver_t low, H5F_libver_t high)
break;
default:
- HDassert(0);
+ assert(0);
break;
} /* end switch */
@@ -1815,7 +1815,7 @@ test_h5s_encode_regular_hyper(H5F_libver_t low, H5F_libver_t high)
expected_enc_size = (uint8_t)(expected_version == 3 ? 4 : 8);
break;
default:
- HDassert(0);
+ assert(0);
break;
} /* end switch */
@@ -1840,7 +1840,7 @@ test_h5s_encode_regular_hyper(H5F_libver_t low, H5F_libver_t high)
expected_enc_size = 8;
break;
default:
- HDassert(0);
+ assert(0);
break;
}
@@ -1865,7 +1865,7 @@ test_h5s_encode_regular_hyper(H5F_libver_t low, H5F_libver_t high)
expected_enc_size = 8;
break;
default:
- HDassert(0);
+ assert(0);
break;
} /* end switch */
@@ -1890,7 +1890,7 @@ test_h5s_encode_regular_hyper(H5F_libver_t low, H5F_libver_t high)
expected_enc_size = 8;
break;
default:
- HDassert(0);
+ assert(0);
break;
}
@@ -1984,7 +1984,7 @@ test_h5s_encode_irregular_hyper(H5F_libver_t low, H5F_libver_t high)
break;
default:
- HDassert(0);
+ assert(0);
break;
}
@@ -2013,7 +2013,7 @@ test_h5s_encode_irregular_hyper(H5F_libver_t low, H5F_libver_t high)
break;
default:
- HDassert(0);
+ assert(0);
break;
}
@@ -2026,7 +2026,7 @@ test_h5s_encode_irregular_hyper(H5F_libver_t low, H5F_libver_t high)
VERIFY(is_regular, FALSE, "H5Sis_regular_hyperslab");
/* Verify the version and encoded size expected for the configuration */
- HDassert(expected_enc_size <= 255);
+ assert(expected_enc_size <= 255);
ret = test_h5s_check_encoding(fapl, sid, expected_version, (uint8_t)expected_enc_size,
expected_to_fail);
CHECK(ret, FAIL, "test_h5s_check_encoding");
diff --git a/test/API/tselect.c b/test/API/tselect.c
index 292bf84..619df42 100644
--- a/test/API/tselect.c
+++ b/test/API/tselect.c
@@ -1886,8 +1886,8 @@ verify_select_hyper_contig_dr__run_test(const uint16_t *cube_buf, size_t cube_si
size_t s; /* Local index variable */
hbool_t mis_match; /* Flag to indicate mismatch in expected value */
- HDassert(cube_buf);
- HDassert(cube_size > 0);
+ assert(cube_buf);
+ assert(cube_size > 0);
expected_value = 0;
mis_match = FALSE;
@@ -1904,7 +1904,7 @@ verify_select_hyper_contig_dr__run_test(const uint16_t *cube_buf, size_t cube_si
m = 0;
do {
/* Sanity check */
- HDassert(s < cube_size);
+ assert(s < cube_size);
/* Check for correct value */
if (*cube_ptr != expected_value)
@@ -1980,12 +1980,12 @@ test_select_hyper_contig_dr__run_test(int test_num, const uint16_t *cube_buf, co
MESSAGE(7, ("\tranks = %u/%u, edge_size = %u, chunk_edge_size = %u.\n", small_rank, large_rank, edge_size,
chunk_edge_size));
- HDassert(edge_size >= 6);
- HDassert(edge_size >= chunk_edge_size);
- HDassert((chunk_edge_size == 0) || (chunk_edge_size >= 3));
- HDassert(small_rank > 0);
- HDassert(small_rank < large_rank);
- HDassert(large_rank <= SS_DR_MAX_RANK);
+ assert(edge_size >= 6);
+ assert(edge_size >= chunk_edge_size);
+ assert((chunk_edge_size == 0) || (chunk_edge_size >= 3));
+ assert(small_rank > 0);
+ assert(small_rank < large_rank);
+ assert(large_rank <= SS_DR_MAX_RANK);
/* Compute cube sizes */
small_cube_size = large_cube_size = (size_t)1;
@@ -1996,7 +1996,7 @@ test_select_hyper_contig_dr__run_test(int test_num, const uint16_t *cube_buf, co
large_cube_size *= (size_t)edge_size;
} /* end for */
- HDassert(large_cube_size < (size_t)UINT_MAX);
+ assert(large_cube_size < (size_t)UINT_MAX);
/* set up the start, stride, count, and block pointers */
start_ptr = &(start[SS_DR_MAX_RANK - large_rank]);
@@ -2242,8 +2242,8 @@ test_select_hyper_contig_dr__run_test(int test_num, const uint16_t *cube_buf, co
(x * edge_size);
stop_index = start_index + small_cube_size - 1;
- HDassert(start_index < stop_index);
- HDassert(stop_index <= large_cube_size);
+ assert(start_index < stop_index);
+ assert(stop_index <= large_cube_size);
mis_match = FALSE;
ptr_1 = large_cube_buf_1;
@@ -2436,8 +2436,8 @@ test_select_hyper_contig_dr__run_test(int test_num, const uint16_t *cube_buf, co
(x * edge_size);
stop_index = start_index + small_cube_size - 1;
- HDassert(start_index < stop_index);
- HDassert(stop_index <= large_cube_size);
+ assert(start_index < stop_index);
+ assert(stop_index <= large_cube_size);
mis_match = FALSE;
ptr_1 = large_cube_buf_1;
@@ -2603,16 +2603,16 @@ test_select_hyper_checker_board_dr__select_checker_board(hid_t tgt_n_cube_sid, u
unsigned u; /* Local index variables */
herr_t ret; /* Generic return value */
- HDassert(edge_size >= 6);
- HDassert(0 < checker_edge_size);
- HDassert(checker_edge_size <= edge_size);
- HDassert(0 < sel_rank);
- HDassert(sel_rank <= tgt_n_cube_rank);
- HDassert(tgt_n_cube_rank <= SS_DR_MAX_RANK);
+ assert(edge_size >= 6);
+ assert(0 < checker_edge_size);
+ assert(checker_edge_size <= edge_size);
+ assert(0 < sel_rank);
+ assert(sel_rank <= tgt_n_cube_rank);
+ assert(tgt_n_cube_rank <= SS_DR_MAX_RANK);
sel_offset = SS_DR_MAX_RANK - sel_rank;
n_cube_offset = SS_DR_MAX_RANK - tgt_n_cube_rank;
- HDassert(n_cube_offset <= sel_offset);
+ assert(n_cube_offset <= sel_offset);
/* First, compute the base count (which assumes start == 0
* for the associated offset) and offset_count (which
@@ -2827,13 +2827,13 @@ test_select_hyper_checker_board_dr__verify_data(uint16_t *buf_ptr, unsigned rank
unsigned v, w, x, y, z; /* to track position in checker */
const unsigned test_max_rank = 5; /* code changes needed if this is increased */
- HDassert(buf_ptr != NULL);
- HDassert(0 < rank);
- HDassert(rank <= test_max_rank);
- HDassert(edge_size >= 6);
- HDassert(0 < checker_edge_size);
- HDassert(checker_edge_size <= edge_size);
- HDassert(test_max_rank <= SS_DR_MAX_RANK);
+ assert(buf_ptr != NULL);
+ assert(0 < rank);
+ assert(rank <= test_max_rank);
+ assert(edge_size >= 6);
+ assert(0 < checker_edge_size);
+ assert(checker_edge_size <= edge_size);
+ assert(test_max_rank <= SS_DR_MAX_RANK);
val_ptr = buf_ptr;
expected_value = first_expected_val;
@@ -2966,15 +2966,15 @@ test_select_hyper_checker_board_dr__run_test(int test_num, const uint16_t *cube_
MESSAGE(7, ("\tranks = %d/%d, edge_size = %d, checker_edge_size = %d, chunk_edge_size = %d.\n",
small_rank, large_rank, edge_size, checker_edge_size, chunk_edge_size));
- HDassert(edge_size >= 6);
- HDassert(checker_edge_size > 0);
- HDassert(checker_edge_size <= edge_size);
- HDassert(edge_size >= chunk_edge_size);
- HDassert((chunk_edge_size == 0) || (chunk_edge_size >= 3));
- HDassert(small_rank > 0);
- HDassert(small_rank < large_rank);
- HDassert(large_rank <= test_max_rank);
- HDassert(test_max_rank <= SS_DR_MAX_RANK);
+ assert(edge_size >= 6);
+ assert(checker_edge_size > 0);
+ assert(checker_edge_size <= edge_size);
+ assert(edge_size >= chunk_edge_size);
+ assert((chunk_edge_size == 0) || (chunk_edge_size >= 3));
+ assert(small_rank > 0);
+ assert(small_rank < large_rank);
+ assert(large_rank <= test_max_rank);
+ assert(test_max_rank <= SS_DR_MAX_RANK);
/* Compute cube sizes */
small_cube_size = large_cube_size = (size_t)1;
@@ -2984,16 +2984,16 @@ test_select_hyper_checker_board_dr__run_test(int test_num, const uint16_t *cube_
large_cube_size *= (size_t)edge_size;
} /* end for */
- HDassert(large_cube_size < (size_t)(UINT_MAX));
+ assert(large_cube_size < (size_t)(UINT_MAX));
small_rank_offset = test_max_rank - small_rank;
- HDassert(small_rank_offset >= 1);
+ assert(small_rank_offset >= 1);
/* also, at present, we use 16 bit values in this test --
* hence the following assertion. Delete it if we convert
* to 32 bit values.
*/
- HDassert(large_cube_size < (size_t)(64 * 1024));
+ assert(large_cube_size < (size_t)(64 * 1024));
/* Allocate & initialize buffers */
small_cube_buf_1 = (uint16_t *)HDcalloc(sizeof(uint16_t), small_cube_size);
@@ -3160,11 +3160,11 @@ test_select_hyper_checker_board_dr__run_test(int test_num, const uint16_t *cube_
* need for another inner loop.
*/
- HDassert((sel_start[0] == 0) || (0 < small_rank_offset));
- HDassert((sel_start[1] == 0) || (1 < small_rank_offset));
- HDassert((sel_start[2] == 0) || (2 < small_rank_offset));
- HDassert((sel_start[3] == 0) || (3 < small_rank_offset));
- HDassert((sel_start[4] == 0) || (4 < small_rank_offset));
+ assert((sel_start[0] == 0) || (0 < small_rank_offset));
+ assert((sel_start[1] == 0) || (1 < small_rank_offset));
+ assert((sel_start[2] == 0) || (2 < small_rank_offset));
+ assert((sel_start[3] == 0) || (3 < small_rank_offset));
+ assert((sel_start[4] == 0) || (4 < small_rank_offset));
test_select_hyper_checker_board_dr__select_checker_board(
file_large_cube_sid, large_rank, edge_size, checker_edge_size, small_rank, sel_start);
@@ -3240,11 +3240,11 @@ test_select_hyper_checker_board_dr__run_test(int test_num, const uint16_t *cube_
* need for another inner loop.
*/
- HDassert((sel_start[0] == 0) || (0 < small_rank_offset));
- HDassert((sel_start[1] == 0) || (1 < small_rank_offset));
- HDassert((sel_start[2] == 0) || (2 < small_rank_offset));
- HDassert((sel_start[3] == 0) || (3 < small_rank_offset));
- HDassert((sel_start[4] == 0) || (4 < small_rank_offset));
+ assert((sel_start[0] == 0) || (0 < small_rank_offset));
+ assert((sel_start[1] == 0) || (1 < small_rank_offset));
+ assert((sel_start[2] == 0) || (2 < small_rank_offset));
+ assert((sel_start[3] == 0) || (3 < small_rank_offset));
+ assert((sel_start[4] == 0) || (4 < small_rank_offset));
test_select_hyper_checker_board_dr__select_checker_board(
mem_large_cube_sid, large_rank, edge_size, checker_edge_size, small_rank, sel_start);
@@ -3274,8 +3274,8 @@ test_select_hyper_checker_board_dr__run_test(int test_num, const uint16_t *cube_
(x * edge_size);
stop_index = start_index + small_cube_size - 1;
- HDassert(start_index < stop_index);
- HDassert(stop_index <= large_cube_size);
+ assert(start_index < stop_index);
+ assert(stop_index <= large_cube_size);
/* verify that the large cube contains only zeros before the slice */
for (s = 0; s < start_index; s++) {
@@ -3283,7 +3283,7 @@ test_select_hyper_checker_board_dr__run_test(int test_num, const uint16_t *cube_
data_ok = FALSE;
ptr_1++;
} /* end for */
- HDassert(s == start_index);
+ assert(s == start_index);
data_ok &= test_select_hyper_checker_board_dr__verify_data(
ptr_1, small_rank, edge_size, checker_edge_size, (uint16_t)0, (hbool_t)TRUE);
@@ -3291,7 +3291,7 @@ test_select_hyper_checker_board_dr__run_test(int test_num, const uint16_t *cube_
ptr_1 += small_cube_size;
s += small_cube_size;
- HDassert(s == stop_index + 1);
+ assert(s == stop_index + 1);
/* verify that the large cube contains only zeros after the slice */
for (s = stop_index + 1; s < large_cube_size; s++) {
@@ -3360,11 +3360,11 @@ test_select_hyper_checker_board_dr__run_test(int test_num, const uint16_t *cube_
* need for another inner loop.
*/
- HDassert((sel_start[0] == 0) || (0 < small_rank_offset));
- HDassert((sel_start[1] == 0) || (1 < small_rank_offset));
- HDassert((sel_start[2] == 0) || (2 < small_rank_offset));
- HDassert((sel_start[3] == 0) || (3 < small_rank_offset));
- HDassert((sel_start[4] == 0) || (4 < small_rank_offset));
+ assert((sel_start[0] == 0) || (0 < small_rank_offset));
+ assert((sel_start[1] == 0) || (1 < small_rank_offset));
+ assert((sel_start[2] == 0) || (2 < small_rank_offset));
+ assert((sel_start[3] == 0) || (3 < small_rank_offset));
+ assert((sel_start[4] == 0) || (4 < small_rank_offset));
test_select_hyper_checker_board_dr__select_checker_board(
mem_large_cube_sid, large_rank, edge_size, checker_edge_size, small_rank, sel_start);
@@ -3455,11 +3455,11 @@ test_select_hyper_checker_board_dr__run_test(int test_num, const uint16_t *cube_
* need for another inner loop.
*/
- HDassert((sel_start[0] == 0) || (0 < small_rank_offset));
- HDassert((sel_start[1] == 0) || (1 < small_rank_offset));
- HDassert((sel_start[2] == 0) || (2 < small_rank_offset));
- HDassert((sel_start[3] == 0) || (3 < small_rank_offset));
- HDassert((sel_start[4] == 0) || (4 < small_rank_offset));
+ assert((sel_start[0] == 0) || (0 < small_rank_offset));
+ assert((sel_start[1] == 0) || (1 < small_rank_offset));
+ assert((sel_start[2] == 0) || (2 < small_rank_offset));
+ assert((sel_start[3] == 0) || (3 < small_rank_offset));
+ assert((sel_start[4] == 0) || (4 < small_rank_offset));
test_select_hyper_checker_board_dr__select_checker_board(
file_large_cube_sid, large_rank, edge_size, checker_edge_size, small_rank, sel_start);
@@ -3498,8 +3498,8 @@ test_select_hyper_checker_board_dr__run_test(int test_num, const uint16_t *cube_
(x * edge_size);
stop_index = start_index + small_cube_size - 1;
- HDassert(start_index < stop_index);
- HDassert(stop_index <= large_cube_size);
+ assert(start_index < stop_index);
+ assert(stop_index <= large_cube_size);
/* verify that the large cube contains only zeros before the slice */
for (s = 0; s < start_index; s++) {
@@ -3507,7 +3507,7 @@ test_select_hyper_checker_board_dr__run_test(int test_num, const uint16_t *cube_
data_ok = FALSE;
ptr_1++;
} /* end for */
- HDassert(s == start_index);
+ assert(s == start_index);
/* verify that the slice contains the expected data */
data_ok &= test_select_hyper_checker_board_dr__verify_data(
@@ -3516,7 +3516,7 @@ test_select_hyper_checker_board_dr__run_test(int test_num, const uint16_t *cube_
ptr_1 += small_cube_size;
s += small_cube_size;
- HDassert(s == stop_index + 1);
+ assert(s == stop_index + 1);
/* verify that the large cube contains only zeros after the slice */
for (s = stop_index + 1; s < large_cube_size; s++) {
@@ -5569,7 +5569,7 @@ test_select_hyper_valid_combination(void)
/* Output message about test being performed */
MESSAGE(6, ("Testing Selection Combination Validity\n"));
- HDassert(SPACE9_DIM2 >= POINT1_NPOINTS);
+ assert(SPACE9_DIM2 >= POINT1_NPOINTS);
/* Create dataspace for single point selection */
single_pt_sid = H5Screate_simple(SPACE9_RANK, dims2D, NULL);
@@ -8459,7 +8459,7 @@ test_shape_same(void)
/* Output message about test being performed */
MESSAGE(6, ("Testing Same Shape Comparisons\n"));
- HDassert(SPACE9_DIM2 >= POINT1_NPOINTS);
+ assert(SPACE9_DIM2 >= POINT1_NPOINTS);
/* Create dataspace for "all" selection */
all_sid = H5Screate_simple(SPACE9_RANK, dims, NULL);
@@ -10912,13 +10912,13 @@ test_shape_same_dr__full_space_vs_slice(int test_num, int small_rank, int large_
htri_t check; /* Shape comparison return value */
herr_t ret; /* Generic return value */
- HDassert(0 < small_rank);
- HDassert(small_rank <= large_rank);
- HDassert(large_rank <= SS_DR_MAX_RANK);
- HDassert(0 <= offset);
- HDassert(offset < large_rank);
- HDassert(edge_size > 0);
- HDassert(edge_size <= 1000);
+ assert(0 < small_rank);
+ assert(small_rank <= large_rank);
+ assert(large_rank <= SS_DR_MAX_RANK);
+ assert(0 <= offset);
+ assert(offset < large_rank);
+ assert(edge_size > 0);
+ assert(edge_size <= 1000);
HDsnprintf(test_desc_0, sizeof(test_desc_0), "\tn-cube slice through m-cube (n <= m) test %d.\n",
test_num);
@@ -10970,7 +10970,7 @@ test_shape_same_dr__full_space_vs_slice(int test_num, int small_rank, int large_
*/
i = SS_DR_MAX_RANK - large_rank;
- HDassert(i >= 0);
+ assert(i >= 0);
start_ptr = &(start[i]);
stride_ptr = &(stride[i]);
@@ -11164,21 +11164,21 @@ test_shape_same_dr__checkerboard(int test_num, int small_rank, int large_rank, i
htri_t check; /* Shape comparison return value */
herr_t ret; /* Generic return value */
- HDassert(0 < small_rank);
- HDassert(small_rank <= large_rank);
- HDassert(large_rank <= SS_DR_MAX_RANK);
- HDassert(0 < checker_size);
- HDassert(checker_size <= edge_size);
- HDassert(edge_size <= 1000);
- HDassert(0 <= offset);
- HDassert(offset < (int)edge_size);
+ assert(0 < small_rank);
+ assert(small_rank <= large_rank);
+ assert(large_rank <= SS_DR_MAX_RANK);
+ assert(0 < checker_size);
+ assert(checker_size <= edge_size);
+ assert(edge_size <= 1000);
+ assert(0 <= offset);
+ assert(offset < (int)edge_size);
for (i = SS_DR_MAX_RANK - large_rank; i < SS_DR_MAX_RANK; i++)
if (dim_selected[i] == TRUE)
dims_selected++;
- HDassert(dims_selected >= 0);
- HDassert(dims_selected <= large_rank);
+ assert(dims_selected >= 0);
+ assert(dims_selected <= large_rank);
HDsnprintf(test_desc_0, sizeof(test_desc_0),
"\tcheckerboard n-cube slice through m-cube (n <= m) test %d.\n", test_num);
@@ -11367,7 +11367,7 @@ test_shape_same_dr__checkerboard(int test_num, int small_rank, int large_rank, i
*/
i = SS_DR_MAX_RANK - large_rank;
- HDassert(i >= 0);
+ assert(i >= 0);
start_ptr = &(start[i]);
stride_ptr = &(stride[i]);
@@ -11708,22 +11708,22 @@ test_shape_same_dr__irregular(int test_num, int small_rank, int large_rank, int
htri_t check; /* Shape comparison return value */
herr_t ret; /* Generic return value */
- HDassert(0 < small_rank);
- HDassert(small_rank <= large_rank);
- HDassert(large_rank <= SS_DR_MAX_RANK);
- HDassert(9 <= edge_size);
- HDassert(edge_size <= 1000);
- HDassert(0 <= slice_offset);
- HDassert(slice_offset < edge_size);
- HDassert(-2 <= pattern_offset);
- HDassert(pattern_offset <= 2);
+ assert(0 < small_rank);
+ assert(small_rank <= large_rank);
+ assert(large_rank <= SS_DR_MAX_RANK);
+ assert(9 <= edge_size);
+ assert(edge_size <= 1000);
+ assert(0 <= slice_offset);
+ assert(slice_offset < edge_size);
+ assert(-2 <= pattern_offset);
+ assert(pattern_offset <= 2);
for (i = SS_DR_MAX_RANK - large_rank; i < SS_DR_MAX_RANK; i++)
if (dim_selected[i] == TRUE)
dims_selected++;
- HDassert(dims_selected >= 0);
- HDassert(dims_selected <= large_rank);
+ assert(dims_selected >= 0);
+ assert(dims_selected <= large_rank);
HDsnprintf(test_desc_0, sizeof(test_desc_0),
"\tirregular sub set of n-cube slice through m-cube (n <= m) test %d.\n", test_num);
@@ -11821,7 +11821,7 @@ test_shape_same_dr__irregular(int test_num, int small_rank, int large_rank, int
*/
i = SS_DR_MAX_RANK - large_rank;
- HDassert(i >= 0);
+ assert(i >= 0);
start_ptr = &(start[i]);
stride_ptr = &(stride[i]);
@@ -14327,7 +14327,7 @@ test_hyper_unlim_check(hid_t sid, hsize_t *dims, hssize_t endpoints, hssize_t en
hsize_t blocklist[12];
herr_t ret;
- HDassert(enblocks <= 2);
+ assert(enblocks <= 2);
/* Copy sid to lim_sid */
lim_sid = H5Scopy(sid);
@@ -14365,7 +14365,7 @@ test_hyper_unlim_check(hid_t sid, hsize_t *dims, hssize_t endpoints, hssize_t en
ERROR("H5Sget_select_hyper_blocklist");
} /* end if */
else {
- HDassert(nblocks == (hssize_t)2);
+ assert(nblocks == (hssize_t)2);
if (HDmemcmp(blocklist, eblock1, 6 * sizeof(eblock1[0])) != 0) {
if (HDmemcmp(blocklist, eblock2, 6 * sizeof(eblock2[0])) != 0)
ERROR("H5Sget_select_hyper_blocklist");
@@ -14795,7 +14795,7 @@ test_internal_consistency(void)
/* Output message about test being performed */
MESSAGE(6, ("Testing Consistency of Internal States\n"));
- HDassert(SPACE9_DIM2 >= POINT1_NPOINTS);
+ assert(SPACE9_DIM2 >= POINT1_NPOINTS);
/* Create dataspace for "all" selection */
all_sid = H5Screate_simple(SPACE9_RANK, dims, NULL);
@@ -15362,7 +15362,7 @@ test_sel_iter(void)
case H5S_SEL_ERROR:
case H5S_SEL_N:
default:
- HDassert(0 && "Can't occur");
+ assert(0 && "Can't occur");
break;
} /* end switch */
@@ -15410,7 +15410,7 @@ test_sel_iter(void)
case H5S_SEL_ERROR:
case H5S_SEL_N:
default:
- HDassert(0 && "Can't occur");
+ assert(0 && "Can't occur");
break;
} /* end switch */
@@ -15481,7 +15481,7 @@ test_sel_iter(void)
case H5S_SEL_ERROR:
case H5S_SEL_N:
default:
- HDassert(0 && "Can't occur");
+ assert(0 && "Can't occur");
break;
} /* end switch */
@@ -15529,7 +15529,7 @@ test_sel_iter(void)
case H5S_SEL_ERROR:
case H5S_SEL_N:
default:
- HDassert(0 && "Can't occur");
+ assert(0 && "Can't occur");
break;
} /* end switch */
@@ -15567,7 +15567,7 @@ test_sel_iter(void)
case H5S_SEL_ERROR:
case H5S_SEL_N:
default:
- HDassert(0 && "Can't occur");
+ assert(0 && "Can't occur");
break;
} /* end switch */
diff --git a/test/API/tunicode.c b/test/API/tunicode.c
index fa59456..04d0d8b 100644
--- a/test/API/tunicode.c
+++ b/test/API/tunicode.c
@@ -152,7 +152,7 @@ test_strpad(hid_t H5_ATTR_UNUSED fid, const char *string)
/* Create a src_type that holds the UTF-8 string and its final NULL */
big_len = length + 1; /* +1 byte for final NULL */
- HDassert((2 * big_len) <= sizeof(cmpbuf));
+ assert((2 * big_len) <= sizeof(cmpbuf));
src_type = mkstr(big_len, H5T_STR_NULLTERM);
CHECK(src_type, FAIL, "mkstr");
/* Create a dst_type that holds half of the UTF-8 string and a final
@@ -215,7 +215,7 @@ test_strpad(hid_t H5_ATTR_UNUSED fid, const char *string)
/* Create a src_type that holds the UTF-8 string */
big_len = length;
- HDassert((2 * big_len) <= sizeof(cmpbuf));
+ assert((2 * big_len) <= sizeof(cmpbuf));
src_type = mkstr(big_len, H5T_STR_NULLPAD);
CHECK(src_type, FAIL, "mkstr");
/* Create a dst_type that holds half of the UTF-8 string */
diff --git a/test/API/tvltypes.c b/test/API/tvltypes.c
index eca534b..a17589b 100644
--- a/test/API/tvltypes.c
+++ b/test/API/tvltypes.c
@@ -2693,13 +2693,13 @@ test_vltypes_fill_value(void)
} break;
case H5D_VIRTUAL:
- HDassert(0 && "Invalid layout type!");
+ assert(0 && "Invalid layout type!");
break;
case H5D_LAYOUT_ERROR:
case H5D_NLAYOUTS:
default:
- HDassert(0 && "Unknown layout type!");
+ assert(0 && "Unknown layout type!");
break;
} /* end switch */
@@ -2801,13 +2801,13 @@ test_vltypes_fill_value(void)
break;
case H5D_VIRTUAL:
- HDassert(0 && "Invalid layout type!");
+ assert(0 && "Invalid layout type!");
break;
case H5D_LAYOUT_ERROR:
case H5D_NLAYOUTS:
default:
- HDassert(0 && "Unknown layout type!");
+ assert(0 && "Unknown layout type!");
break;
} /* end switch */
@@ -2988,13 +2988,13 @@ test_vltypes_fill_value(void)
break;
case H5D_VIRTUAL:
- HDassert(0 && "Invalid layout type!");
+ assert(0 && "Invalid layout type!");
break;
case H5D_LAYOUT_ERROR:
case H5D_NLAYOUTS:
default:
- HDassert(0 && "Unknown layout type!");
+ assert(0 && "Unknown layout type!");
break;
} /* end switch */