summaryrefslogtreecommitdiff
path: root/numpy/ma/tests
diff options
context:
space:
mode:
Diffstat (limited to 'numpy/ma/tests')
-rw-r--r--numpy/ma/tests/test_core.py3
-rw-r--r--numpy/ma/tests/test_old_ma.py8
2 files changed, 5 insertions, 6 deletions
diff --git a/numpy/ma/tests/test_core.py b/numpy/ma/tests/test_core.py
index 7eb4bbed2..81114fb2e 100644
--- a/numpy/ma/tests/test_core.py
+++ b/numpy/ma/tests/test_core.py
@@ -12,6 +12,7 @@ import types
import warnings
import sys
import pickle
+from functools import reduce
import numpy as np
import numpy.ma.core
@@ -24,8 +25,6 @@ from numpy.testing.utils import WarningManager
pi = np.pi
-if sys.version_info[0] >= 3:
- from functools import reduce
#..............................................................................
class TestMaskedArray(TestCase):
diff --git a/numpy/ma/tests/test_old_ma.py b/numpy/ma/tests/test_old_ma.py
index 41f7779d9..ba2b3fbf8 100644
--- a/numpy/ma/tests/test_old_ma.py
+++ b/numpy/ma/tests/test_old_ma.py
@@ -1,15 +1,15 @@
from __future__ import division, absolute_import
-import numpy
+import sys
import types
+from functools import reduce
+
+import numpy
from numpy.ma import *
from numpy.core.numerictypes import float32
from numpy.ma.core import umath
from numpy.testing import *
-import sys
-if sys.version_info[0] >= 3:
- from functools import reduce
pi = numpy.pi
def eq(v, w, msg=''):