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/88da6201d08b
branches:  trunk
changeset: 451551:88da6201d08b
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 23508a6dbd16 -r 88da6201d08b 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