summaryrefslogtreecommitdiffstats
path: root/test
diff options
context:
space:
mode:
authorDana Robinson <43805+derobins@users.noreply.github.com>2022-09-17 16:49:38 (GMT)
committerGitHub <noreply@github.com>2022-09-17 16:49:38 (GMT)
commit6d89634445eb70cc5fb2f29e2c8ea21eebf4436d (patch)
tree47125fcfdf46020e947972094a3df30e84fc511d /test
parenta9d8b469f46d2f5de7521b986d2e14725e081eb9 (diff)
downloadhdf5-6d89634445eb70cc5fb2f29e2c8ea21eebf4436d.zip
hdf5-6d89634445eb70cc5fb2f29e2c8ea21eebf4436d.tar.gz
hdf5-6d89634445eb70cc5fb2f29e2c8ea21eebf4436d.tar.bz2
Updates VOL capabilities flags (#2105)
* Added feature/vol_cap_flags branch to GitHub actions * Convert unsigned cap flag field to uint64_t and add flags * Committing clang-format changes * Convert unsigned cap flag field to uint64_t and add flags * Committing clang-format changes * Updates the VOL struct version number Co-authored-by: github-actions <41898282+github-actions[bot]@users.noreply.github.com>
Diffstat (limited to 'test')
-rw-r--r--test/null_vol_connector.c2
-rw-r--r--test/vol.c44
2 files changed, 23 insertions, 23 deletions
diff --git a/test/null_vol_connector.c b/test/null_vol_connector.c
index 6555763..ed1adbb 100644
--- a/test/null_vol_connector.c
+++ b/test/null_vol_connector.c
@@ -27,7 +27,7 @@ static const H5VL_class_t null_vol_g = {
NULL_VOL_CONNECTOR_VALUE, /* value */
NULL_VOL_CONNECTOR_NAME, /* name */
0, /* connector version */
- 0, /* capability flags */
+ H5VL_CAP_FLAG_NONE, /* capability flags */
NULL, /* initialize */
NULL, /* terminate */
{
diff --git a/test/vol.c b/test/vol.c
index 8a95847..a39ce96 100644
--- a/test/vol.c
+++ b/test/vol.c
@@ -50,13 +50,13 @@ static herr_t reg_opt_datatype_get(void *obj, H5VL_datatype_get_args_t *args, hi
#define REG_OPT_VOL_NAME "reg_opt"
#define REG_OPT_VOL_VALUE ((H5VL_class_value_t)502)
static const H5VL_class_t reg_opt_vol_g = {
- H5VL_VERSION, /* VOL class struct version */
- REG_OPT_VOL_VALUE, /* value */
- REG_OPT_VOL_NAME, /* name */
- 0, /* version */
- 0, /* capability flags */
- NULL, /* initialize */
- NULL, /* terminate */
+ H5VL_VERSION, /* VOL class struct version */
+ REG_OPT_VOL_VALUE, /* value */
+ REG_OPT_VOL_NAME, /* name */
+ 0, /* version */
+ H5VL_CAP_FLAG_NONE, /* capability flags */
+ NULL, /* initialize */
+ NULL, /* terminate */
{
/* info_cls */
(size_t)0, /* size */
@@ -178,13 +178,13 @@ static const H5VL_class_t reg_opt_vol_g = {
* functionality.
*/
static const H5VL_class_t fake_vol_g = {
- H5VL_VERSION, /* VOL class struct version */
- FAKE_VOL_VALUE, /* value */
- FAKE_VOL_NAME, /* name */
- 0, /* connector version */
- 0, /* capability flags */
- NULL, /* initialize */
- NULL, /* terminate */
+ H5VL_VERSION, /* VOL class struct version */
+ FAKE_VOL_VALUE, /* value */
+ FAKE_VOL_NAME, /* name */
+ 0, /* connector version */
+ H5VL_CAP_FLAG_NONE, /* capability flags */
+ NULL, /* initialize */
+ NULL, /* terminate */
{
/* info_cls */
(size_t)0, /* size */
@@ -299,7 +299,7 @@ static const H5VL_class_t fake_vol_g = {
NULL /* optional */
};
-static herr_t fake_async_get_cap_flags(const void *info, unsigned *cap_flags);
+static herr_t fake_async_get_cap_flags(const void *info, uint64_t *cap_flags);
#define FAKE_ASYNC_VOL_NAME "fake_async"
#define FAKE_ASYNC_VOL_VALUE ((H5VL_class_value_t)503)
@@ -562,7 +562,7 @@ reg_opt_datatype_get(void H5_ATTR_UNUSED *obj, H5VL_datatype_get_args_t *args, h
*-------------------------------------------------------------------------
*/
static herr_t
-fake_async_get_cap_flags(const void H5_ATTR_UNUSED *info, unsigned *cap_flags)
+fake_async_get_cap_flags(const void H5_ATTR_UNUSED *info, uint64_t *cap_flags)
{
*cap_flags = fake_async_vol_g.cap_flags;
@@ -1979,7 +1979,7 @@ test_async_vol_props(void)
hid_t fapl_id = H5I_INVALID_HID;
hid_t vol_id = H5I_INVALID_HID;
H5VL_pass_through_info_t passthru_info;
- unsigned cap_flags = 0;
+ uint64_t cap_flags = H5VL_CAP_FLAG_NONE;
char *conn_env_str = NULL;
TESTING("Async VOL props");
@@ -2002,7 +2002,7 @@ test_async_vol_props(void)
TEST_ERROR;
if (H5VL__reparse_def_vol_conn_variable_test() < 0)
TEST_ERROR;
- } /* end if */
+ }
/* Test query w/default VOL, which should indicate no async, since native connector
* doesn't support async.
@@ -2032,7 +2032,7 @@ test_async_vol_props(void)
fapl_id = h5_fileaccess();
/* Test query w/fake async VOL, which should succeed */
- cap_flags = 0;
+ cap_flags = H5VL_CAP_FLAG_NONE;
if (H5Pget_vol_cap_flags(fapl_id, &cap_flags) < 0)
FAIL_STACK_ERROR;
if ((cap_flags & H5VL_CAP_FLAG_ASYNC) == 0)
@@ -2058,7 +2058,7 @@ test_async_vol_props(void)
FAIL_STACK_ERROR;
/* Test query w/fake async VOL, which should succeed */
- cap_flags = 0;
+ cap_flags = H5VL_CAP_FLAG_NONE;
if (H5Pget_vol_cap_flags(fapl_id, &cap_flags) < 0)
FAIL_STACK_ERROR;
if ((cap_flags & H5VL_CAP_FLAG_ASYNC) == 0)
@@ -2073,7 +2073,7 @@ test_async_vol_props(void)
FAIL_STACK_ERROR;
/* Test query w/passthru -> fake async VOL, which should succeed */
- cap_flags = 0;
+ cap_flags = H5VL_CAP_FLAG_NONE;
if (H5Pget_vol_cap_flags(fapl_id, &cap_flags) < 0)
FAIL_STACK_ERROR;
if ((cap_flags & H5VL_CAP_FLAG_ASYNC) == 0)
@@ -2097,7 +2097,7 @@ test_async_vol_props(void)
if (H5VL__reparse_def_vol_conn_variable_test() < 0)
TEST_ERROR;
- } /* end if */
+ }
PASSED();