mirror of https://github.com/ecmwf/eccodes.git
Testing: Increase coverage
This commit is contained in:
parent
cd10437b0a
commit
699491023d
|
@ -23,8 +23,7 @@ int main(int argc, char** argv)
|
||||||
double abs_error = 0;
|
double abs_error = 0;
|
||||||
const double max_abs_error = 1e-03;
|
const double max_abs_error = 1e-03;
|
||||||
const double tolerance = 1e-03;
|
const double tolerance = 1e-03;
|
||||||
double dmin;
|
double dmin, dmax, dval;
|
||||||
double dmax;
|
|
||||||
float fval;
|
float fval;
|
||||||
|
|
||||||
FILE* in = NULL;
|
FILE* in = NULL;
|
||||||
|
@ -44,6 +43,10 @@ int main(int argc, char** argv)
|
||||||
h = codes_handle_new_from_file(0, in, PRODUCT_GRIB, &err);
|
h = codes_handle_new_from_file(0, in, PRODUCT_GRIB, &err);
|
||||||
Assert(h);
|
Assert(h);
|
||||||
|
|
||||||
|
CODES_CHECK(codes_get_float(h, "referenceValue", &fval), 0);
|
||||||
|
CODES_CHECK(codes_get_double(h, "referenceValue", &dval), 0);
|
||||||
|
printf("dval = %g, fval = %g\n", dval, fval);
|
||||||
|
|
||||||
CODES_CHECK(codes_get_size(h, "values", &values_len), 0);
|
CODES_CHECK(codes_get_size(h, "values", &values_len), 0);
|
||||||
|
|
||||||
fvalues = (float*)malloc(values_len * sizeof(float));
|
fvalues = (float*)malloc(values_len * sizeof(float));
|
||||||
|
|
Loading…
Reference in New Issue