summaryrefslogtreecommitdiffstatshomepage
diff options
context:
space:
mode:
-rw-r--r--tests/float/math-fun-bool.py7
-rw-r--r--tests/float/math-fun.py7
2 files changed, 12 insertions, 2 deletions
diff --git a/tests/float/math-fun-bool.py b/tests/float/math-fun-bool.py
index cf718d4b80..57232857ab 100644
--- a/tests/float/math-fun-bool.py
+++ b/tests/float/math-fun-bool.py
@@ -1,6 +1,11 @@
# Test the bool functions from math
-from math import isfinite, isnan, isinf
+try:
+ from math import isfinite, isnan, isinf
+except ImportError:
+ print("SKIP")
+ import sys
+ sys.exit()
test_values = [1, 0, -1, 1.0, 0.0, -1.0, float('NaN'), float('Inf'),
-float('NaN'), -float('Inf')]
diff --git a/tests/float/math-fun.py b/tests/float/math-fun.py
index 7a37c58454..fa111e33e3 100644
--- a/tests/float/math-fun.py
+++ b/tests/float/math-fun.py
@@ -1,6 +1,11 @@
# Tests the functions imported from math
-from math import *
+try:
+ from math import *
+except ImportError:
+ print("SKIP")
+ import sys
+ sys.exit()
test_values = [-100., -1.23456, -1, -0.5, 0.0, 0.5, 1.23456, 100.]
p_test_values = [0.1, 0.5, 1.23456]