summaryrefslogtreecommitdiff
path: root/numpy/ma/tests
diff options
context:
space:
mode:
authorStefan van der Walt <stefan@sun.ac.za>2007-12-15 02:16:30 +0000
committerStefan van der Walt <stefan@sun.ac.za>2007-12-15 02:16:30 +0000
commitfc1506199914b4fcdd2dfb930d9ddc0ee2ee9569 (patch)
treebfa2e12bc000d24f2f6293be7e7ebd2b6db893f5 /numpy/ma/tests
parent4fc786ed80c5b26c8457f8f65bdf58ad67c64b8e (diff)
downloadnumpy-fc1506199914b4fcdd2dfb930d9ddc0ee2ee9569.tar.gz
Ignore warning raised during testing.
Diffstat (limited to 'numpy/ma/tests')
-rw-r--r--numpy/ma/tests/test_core.py4
1 files changed, 4 insertions, 0 deletions
diff --git a/numpy/ma/tests/test_core.py b/numpy/ma/tests/test_core.py
index 0849be135..b70c40996 100644
--- a/numpy/ma/tests/test_core.py
+++ b/numpy/ma/tests/test_core.py
@@ -11,6 +11,7 @@ __revision__ = "$Revision: 3473 $"
__date__ = '$Date: 2007-10-29 17:18:13 +0200 (Mon, 29 Oct 2007) $'
import types
+import warnings
import numpy
import numpy.core.fromnumeric as fromnumeric
@@ -679,7 +680,10 @@ class TestMA(NumpyTestCase):
assert_equal(1, int(array([[[1]]])))
assert_equal(1.0, float(array([[1]])))
self.failUnlessRaises(ValueError, float, array([1,1]))
+
+ warnings.simplefilter('ignore',UserWarning)
assert numpy.isnan(float(array([1],mask=[1])))
+ warnings.simplefilter('default',UserWarning)
#TODO: Check how bool works...
#TODO: self.failUnless(bool(array([0,1])))
#TODO: self.failUnless(bool(array([0,0],mask=[0,1])))