mirror of
https://github.com/HDFGroup/hdf5.git
synced 2025-03-31 17:10:47 +08:00
Pass-through connector testing flexibility (#2399)
* Correct concurrency bugs when running tests, along with a bugfix & small warning cleanup. * Committing clang-format changes * Allow spaces (and tabs) in VOL connector info string from environment variable. * Parse connector name from HDF5_PLUGIN_PATH environment variable better * Correct H5VLquery_optional to use H5VL routine instead of H5I. Also add an error message to the failure return value from not finding a plugin. * Play nice with existing plugin paths * Use API routine to determine if native connector is terminal. * Committing clang-format changes * Make string size larger, to allow for connectors with longer names. * Be more flexible about testing external pass through connectors, especially if they have registered new optional operations. Co-authored-by: github-actions <41898282+github-actions[bot]@users.noreply.github.com> Co-authored-by: AWS ParallelCluster user <ec2-user@ip-10-0-0-65.us-east-2.compute.internal> Co-authored-by: Koziol <qkoziol@88665a374c70.ant.amazon.com>
This commit is contained in:
parent
90d20764f4
commit
06c12f97cd
@ -235,7 +235,7 @@ PROGRAM vol_connector
|
||||
INTEGER :: error
|
||||
INTEGER :: ret_total_error
|
||||
LOGICAL :: cleanup, status
|
||||
CHARACTER(LEN=12) :: VOL_CONNECTOR_ENV
|
||||
CHARACTER(LEN=32) :: VOL_CONNECTOR_ENV
|
||||
INTEGER :: LEN = 0
|
||||
INTEGER :: CONN_NAME_LEN
|
||||
|
||||
|
12
test/vol.c
12
test/vol.c
@ -1664,7 +1664,7 @@ exercise_reg_opt_oper(hid_t fake_vol_id, hid_t reg_opt_vol_id, H5VL_subclass_t s
|
||||
|
||||
/* Verify that the reserved amount of optional operations is obeyed */
|
||||
/* (The first optional operation registered should be at the lower limit) */
|
||||
if (op_val != H5VL_RESERVED_NATIVE_OPTIONAL)
|
||||
if (op_val < H5VL_RESERVED_NATIVE_OPTIONAL)
|
||||
TEST_ERROR;
|
||||
|
||||
/* Look up 1st registered optional operation */
|
||||
@ -1683,7 +1683,7 @@ exercise_reg_opt_oper(hid_t fake_vol_id, hid_t reg_opt_vol_id, H5VL_subclass_t s
|
||||
|
||||
/* Verify that the reserved amount of optional operations is obeyed */
|
||||
/* (The 2nd optional operation registered should be at the lower limit + 1) */
|
||||
if (op_val2 != (H5VL_RESERVED_NATIVE_OPTIONAL + 1))
|
||||
if (op_val2 < (H5VL_RESERVED_NATIVE_OPTIONAL + 1))
|
||||
TEST_ERROR;
|
||||
|
||||
/* Look up 2nd registered optional operation */
|
||||
@ -2242,10 +2242,9 @@ test_get_vol_name(void)
|
||||
conn_env_str = "native";
|
||||
|
||||
/* Skip the connectors other than the native and pass_through connector */
|
||||
if (HDstrcmp(conn_env_str, "native") &&
|
||||
HDstrncmp(conn_env_str, "pass_through", HDstrlen("pass_through"))) {
|
||||
if (HDstrcmp(conn_env_str, "native") && HDstrcmp(conn_env_str, "pass_through")) {
|
||||
SKIPPED();
|
||||
HDprintf(" only test the native or pass_through connector\n");
|
||||
HDprintf(" only test the native or internal pass_through connector\n");
|
||||
return SUCCEED;
|
||||
}
|
||||
|
||||
@ -2262,8 +2261,7 @@ test_get_vol_name(void)
|
||||
|
||||
/* When comparing the pass_through connector, ignore the rest information (under_vol=0;under_info={}) */
|
||||
if ((!HDstrcmp(conn_env_str, "native") && HDstrcmp(vol_name, "native")) ||
|
||||
(!HDstrncmp(conn_env_str, "pass_through", HDstrlen("pass_through")) &&
|
||||
HDstrcmp(vol_name, "pass_through")))
|
||||
(!HDstrcmp(conn_env_str, "pass_through") && HDstrcmp(vol_name, "pass_through")))
|
||||
TEST_ERROR;
|
||||
|
||||
if (H5Fclose(file_id) < 0)
|
||||
|
Loading…
x
Reference in New Issue
Block a user