Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Implement fill value tests #60

Merged
merged 3 commits into from
Sep 1, 2023

Conversation

mattjala
Copy link
Contributor

@mattjala mattjala commented Aug 2, 2023

Currently only tests that fill values work for integers, doubles, and fixed-length strings with ASCII characters, since not all VOLs support more complex datatypes.

for (size_t i = 0; i < num_elems; i++) {
val = (double *)(read_buf) + i;

if (*(double *)val != DATASET_FILL_VALUE_TEST_DOUBLE_FILL_VALUE) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Instead of directly comparing double values for equality, you should use something similar to the H5_DBL_ABS_EQUAL or H5_DBL_REL_EQUAL macros from the library.

@jhendersonHDF jhendersonHDF merged commit 3605116 into HDFGroup:master Sep 1, 2023
@mattjala mattjala deleted the fill_value_tests branch September 6, 2023 15:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants