Skip to content

Commit

Permalink
Convert hbool_t --> bool in test (HDFGroup#3494)
Browse files Browse the repository at this point in the history
  • Loading branch information
derobins authored and qkoziol committed Sep 30, 2023
1 parent 6c98400 commit ff76e94
Show file tree
Hide file tree
Showing 132 changed files with 11,527 additions and 11,544 deletions.
78 changes: 39 additions & 39 deletions test/API/H5_api_async_test.c
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ test_one_dataset_io(void)
hid_t es_id = H5I_INVALID_HID;
hsize_t dims[2] = {6, 10};
size_t num_in_progress;
hbool_t op_failed;
bool op_failed;
int wbuf[6][10];
int rbuf[6][10];
int i, j;
Expand Down Expand Up @@ -328,7 +328,7 @@ test_multi_dataset_io(void)
hid_t es_id = H5I_INVALID_HID;
hsize_t dims[2] = {6, 10};
size_t num_in_progress;
hbool_t op_failed;
bool op_failed;
char dset_name[32];
int wbuf[5][6][10];
int rbuf[5][6][10];
Expand Down Expand Up @@ -582,7 +582,7 @@ test_multi_file_dataset_io(void)
hid_t es_id = H5I_INVALID_HID;
hsize_t dims[2] = {6, 10};
size_t num_in_progress;
hbool_t op_failed;
bool op_failed;
char file_name[32];
int wbuf[5][6][10];
int rbuf[5][6][10];
Expand Down Expand Up @@ -892,7 +892,7 @@ test_multi_file_grp_dset_io(void)
hid_t es_id = H5I_INVALID_HID;
hsize_t dims[2] = {6, 10};
size_t num_in_progress;
hbool_t op_failed;
bool op_failed;
char file_name[32];
int wbuf[5][6][10];
int rbuf[5][6][10];
Expand Down Expand Up @@ -1208,7 +1208,7 @@ test_set_extent(void)
hsize_t start[2] = {0, 0};
hsize_t count[2] = {1, 10};
size_t num_in_progress;
hbool_t op_failed;
bool op_failed;
htri_t tri_ret;
int wbuf[6][10];
int rbuf[6][10];
Expand Down Expand Up @@ -1413,10 +1413,10 @@ test_attribute_exists(void)
hid_t space_id = H5I_INVALID_HID;
hid_t es_id = H5I_INVALID_HID;
hsize_t dims[2] = {6, 10};
hbool_t exists1;
hbool_t exists2;
bool exists1;
bool exists2;
size_t num_in_progress;
hbool_t op_failed;
bool op_failed;

TESTING("H5Aexists()");

Expand Down Expand Up @@ -1479,9 +1479,9 @@ test_attribute_exists(void)

/* Check if H5Aexists returned the correct values */
if (exists1)
FAIL_PUTS_ERROR(" H5Aexists returned TRUE for an attribute that should not exist");
FAIL_PUTS_ERROR(" H5Aexists returned true for an attribute that should not exist");
if (!exists2)
FAIL_PUTS_ERROR(" H5Aexists returned FALSE for an attribute that should exist");
FAIL_PUTS_ERROR(" H5Aexists returned false for an attribute that should exist");

/* Close */
if (H5Aclose_async(attr_id, es_id) < 0)
Expand Down Expand Up @@ -1534,7 +1534,7 @@ test_attribute_io(void)
hid_t es_id = H5I_INVALID_HID;
hsize_t dims[2] = {6, 10};
size_t num_in_progress;
hbool_t op_failed;
bool op_failed;
int wbuf[6][10];
int rbuf[6][10];
int i, j;
Expand Down Expand Up @@ -1676,7 +1676,7 @@ test_attribute_io_tconv(void)
hid_t es_id = H5I_INVALID_HID;
hsize_t dims[2] = {6, 10};
size_t num_in_progress;
hbool_t op_failed;
bool op_failed;
int wbuf[6][10];
int rbuf[6][10];
int i, j;
Expand Down Expand Up @@ -1821,7 +1821,7 @@ test_attribute_io_compound(void)
hid_t es_id = H5I_INVALID_HID;
hsize_t dims[2] = {6, 10};
size_t num_in_progress;
hbool_t op_failed;
bool op_failed;
tattr_cmpd_t wbuf[6][10];
tattr_cmpd_t rbuf[6][10];
tattr_cmpd_t fbuf[6][10];
Expand Down Expand Up @@ -2131,7 +2131,7 @@ test_group(void)
H5G_info_t info2;
H5G_info_t info3;
size_t num_in_progress;
hbool_t op_failed;
bool op_failed;

TESTING("group operations");

Expand Down Expand Up @@ -2288,19 +2288,19 @@ test_group(void)
static int
test_link(void)
{
hid_t file_id = H5I_INVALID_HID;
hid_t parent_group_id = H5I_INVALID_HID;
hid_t group_id = H5I_INVALID_HID;
hid_t gcpl_id = H5I_INVALID_HID;
hid_t es_id = H5I_INVALID_HID;
hbool_t existsh1;
hbool_t existsh2;
hbool_t existsh3;
hbool_t existss1;
hbool_t existss2;
hbool_t existss3;
size_t num_in_progress;
hbool_t op_failed;
hid_t file_id = H5I_INVALID_HID;
hid_t parent_group_id = H5I_INVALID_HID;
hid_t group_id = H5I_INVALID_HID;
hid_t gcpl_id = H5I_INVALID_HID;
hid_t es_id = H5I_INVALID_HID;
bool existsh1;
bool existsh2;
bool existsh3;
bool existss1;
bool existss2;
bool existss3;
size_t num_in_progress;
bool op_failed;

TESTING("link operations");

Expand Down Expand Up @@ -2431,17 +2431,17 @@ test_link(void)

/* Check if existence returns were correct */
if (!existsh1)
FAIL_PUTS_ERROR(" link exists returned FALSE for link that should exist");
FAIL_PUTS_ERROR(" link exists returned false for link that should exist");
if (!existss1)
FAIL_PUTS_ERROR(" link exists returned FALSE for link that should exist");
FAIL_PUTS_ERROR(" link exists returned false for link that should exist");
if (!existsh2)
FAIL_PUTS_ERROR(" link exists returned FALSE for link that should exist");
FAIL_PUTS_ERROR(" link exists returned false for link that should exist");
if (existss2)
FAIL_PUTS_ERROR(" link exists returned TRUE for link that should not exist");
FAIL_PUTS_ERROR(" link exists returned true for link that should not exist");
if (existsh3)
FAIL_PUTS_ERROR(" link exists returned TRUE for link that should not exist");
FAIL_PUTS_ERROR(" link exists returned true for link that should not exist");
if (existsh3)
FAIL_PUTS_ERROR(" link exists returned TRUE for link that should not exist");
FAIL_PUTS_ERROR(" link exists returned true for link that should not exist");

/* Close */
if (H5Gclose_async(parent_group_id, es_id) < 0)
Expand Down Expand Up @@ -2492,7 +2492,7 @@ test_ocopy_orefresh(void)
hid_t es_id = H5I_INVALID_HID;
hsize_t dims[2] = {6, 10};
size_t num_in_progress;
hbool_t op_failed;
bool op_failed;

TESTING("H5Ocopy() and H5Orefresh()");

Expand Down Expand Up @@ -2600,11 +2600,11 @@ test_ocopy_orefresh(void)
static int
test_file_reopen(void)
{
hid_t file_id = H5I_INVALID_HID;
hid_t reopened_file_id = H5I_INVALID_HID;
hid_t es_id = H5I_INVALID_HID;
size_t num_in_progress;
hbool_t op_failed;
hid_t file_id = H5I_INVALID_HID;
hid_t reopened_file_id = H5I_INVALID_HID;
hid_t es_id = H5I_INVALID_HID;
size_t num_in_progress;
bool op_failed;

TESTING("H5Freopen()");

Expand Down
Loading

0 comments on commit ff76e94

Please sign in to comment.