Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/tests/lib/libm Print result of function we tested (sinf),



details:   https://anonhg.NetBSD.org/src/rev/e1bf3e7a6db3
branches:  trunk
changeset: 841651:e1bf3e7a6db3
user:      maya <maya%NetBSD.org@localhost>
date:      Mon May 27 00:24:37 2019 +0000

description:
Print result of function we tested (sinf),
not of function we didn't test (sin).

no need to print 17 digits for a float.

from Riastradh.

diffstat:

 tests/lib/libm/t_sin.c |  6 +++---
 1 files changed, 3 insertions(+), 3 deletions(-)

diffs (20 lines):

diff -r c9bc6f6d3d8f -r e1bf3e7a6db3 tests/lib/libm/t_sin.c
--- a/tests/lib/libm/t_sin.c    Mon May 27 00:10:36 2019 +0000
+++ b/tests/lib/libm/t_sin.c    Mon May 27 00:24:37 2019 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: t_sin.c,v 1.6 2018/11/07 04:00:13 riastradh Exp $ */
+/* $NetBSD: t_sin.c,v 1.7 2019/05/27 00:24:37 maya Exp $ */
 
 /*-
  * Copyright (c) 2011 The NetBSD Foundation, Inc.
@@ -194,8 +194,8 @@
                }
 
                if (!ok) {
-                       atf_tc_fail_nonfatal("sinf(%d deg) = %.17g != %.17g",
-                           deg, (double)sin(theta), (double)sin_theta);
+                       atf_tc_fail_nonfatal("sinf(%d deg) = %.8g != %.8g",
+                           deg, sinf(theta), sin_theta);
                }
        }
 }



Home | Main Index | Thread Index | Old Index