Commits

Armin Rigo committed c57ac70

acosh(x) is only defined for x >= 1.0.

  • Participants
  • Parent commits 13f9e5d
  • Branches fast-forward

Comments (0)

Files changed (1)

pypy/rpython/lltypesystem/module/test/test_llinterp_math.py

         except AttributeError:
             fn = getattr(rarithmetic, name)
             assert_exact = False
+        if name == 'acosh':
+            value = 1.3     # acosh(x) is only defined for x >= 1.0
+        else:
+            value = 0.3
         #
         def next_test(self):
             def f(x):
                 return fn(x)
-            res = self.interpret(f, [0.3])
+            res = self.interpret(f, [value])
             if assert_exact:
-                assert res == f(0.3)
+                assert res == f(value)
             else:
-                assert abs(res - f(0.3)) < 1e-10
+                assert abs(res - f(value)) < 1e-10
         return next_test
 
     def new_binary_test(name):