test: use fabsl instead of fabs as json_variant_real() returns 'long double'
This commit is contained in:
parent
172e4806dd
commit
40990eac27
|
@ -208,7 +208,7 @@ static void test_2(JsonVariant *v) {
|
||||||
|
|
||||||
/* has thisisaverylongproperty */
|
/* has thisisaverylongproperty */
|
||||||
p = json_variant_by_key(v, "thisisaverylongproperty");
|
p = json_variant_by_key(v, "thisisaverylongproperty");
|
||||||
assert_se(p && json_variant_type(p) == JSON_VARIANT_REAL && fabs(json_variant_real(p) - 1.27) < 0.001);
|
assert_se(p && json_variant_type(p) == JSON_VARIANT_REAL && fabsl(json_variant_real(p) - 1.27) < 0.001);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue