Add expm1 test case to cover the k==1024 case (#4508)

-7.095e+02 won't trigger the  k==1024 case, so we didn't add it into the test list

JerryScript-DCO-1.0-Signed-off-by: Yonggang Luo luoyonggang@gmail.com
This commit is contained in:
Yonggang Luo 2021-01-19 06:23:57 +08:00 committed by GitHub
parent cb85797ab5
commit d97540e883
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 2 additions and 0 deletions

View File

@ -294,6 +294,7 @@ check_double ("expm1 (INFINITY)", expm1 (INFINITY), INF);
check_double ("expm1 (-INFINITY)", expm1 (-INFINITY), -1.00000000000000000000E+00);
check_double ("expm1 (NAN)", expm1 (NAN), NAN);
check_double ("expm1 (7.08e+02)", expm1 (7.08e+02), 3.02338314427605515848E+307);
check_double ("expm1 (7.095e+02)", expm1 (7.095e+02), 1.35498631931463283283E+308);
check_double ("expm1 (7.10e+02)", expm1 (7.10e+02), INF);
check_double ("expm1 (-7.40e+02)", expm1 (-7.40e+02), -1.00000000000000000000E+00);
check_double ("expm1 (-7.50e+02)", expm1 (-7.50e+02), -1.00000000000000000000E+00);

View File

@ -405,6 +405,7 @@ main (int argc, char **args)
GEN_DBL_TEST (expm1 (-INFINITY));
GEN_DBL_TEST (expm1 (NAN));
GEN_DBL_TEST (expm1 (7.08e+02));
GEN_DBL_TEST (expm1 (7.095e+02));
GEN_DBL_TEST (expm1 (7.10e+02));
GEN_DBL_TEST (expm1 (-7.40e+02));
GEN_DBL_TEST (expm1 (-7.50e+02));