summaryrefslogtreecommitdiff
path: root/numpy/polynomial/tests/test_polynomial.py
diff options
context:
space:
mode:
Diffstat (limited to 'numpy/polynomial/tests/test_polynomial.py')
-rw-r--r--numpy/polynomial/tests/test_polynomial.py21
1 files changed, 11 insertions, 10 deletions
diff --git a/numpy/polynomial/tests/test_polynomial.py b/numpy/polynomial/tests/test_polynomial.py
index 037be5927..bf6c5e814 100644
--- a/numpy/polynomial/tests/test_polynomial.py
+++ b/numpy/polynomial/tests/test_polynomial.py
@@ -6,8 +6,9 @@ from __future__ import division, absolute_import, print_function
import numpy as np
import numpy.polynomial.polynomial as poly
from numpy.testing import (
- TestCase, assert_almost_equal, assert_raises,
- assert_equal, assert_, run_module_suite)
+ assert_almost_equal, assert_raises, assert_equal, assert_,
+ run_module_suite
+ )
def trim(x):
@@ -27,7 +28,7 @@ T9 = [0, 9, 0, -120, 0, 432, 0, -576, 0, 256]
Tlist = [T0, T1, T2, T3, T4, T5, T6, T7, T8, T9]
-class TestConstants(TestCase):
+class TestConstants(object):
def test_polydomain(self):
assert_equal(poly.polydomain, [-1, 1])
@@ -42,7 +43,7 @@ class TestConstants(TestCase):
assert_equal(poly.polyx, [0, 1])
-class TestArithmetic(TestCase):
+class TestArithmetic(object):
def test_polyadd(self):
for i in range(5):
@@ -103,7 +104,7 @@ class TestArithmetic(TestCase):
assert_equal(res, tgt, err_msg=msg)
-class TestEvaluation(TestCase):
+class TestEvaluation(object):
# coefficients of 1 + 2*x + 3*x**2
c1d = np.array([1., 2., 3.])
c2d = np.einsum('i,j->ij', c1d, c1d)
@@ -263,7 +264,7 @@ class TestEvaluation(TestCase):
assert_(res.shape == (2, 3)*3)
-class TestIntegral(TestCase):
+class TestIntegral(object):
def test_polyint(self):
# check exceptions
@@ -357,7 +358,7 @@ class TestIntegral(TestCase):
assert_almost_equal(res, tgt)
-class TestDerivative(TestCase):
+class TestDerivative(object):
def test_polyder(self):
# check exceptions
@@ -397,7 +398,7 @@ class TestDerivative(TestCase):
assert_almost_equal(res, tgt)
-class TestVander(TestCase):
+class TestVander(object):
# some random values in [-1, 1)
x = np.random.random((3, 5))*2 - 1
@@ -445,7 +446,7 @@ class TestVander(TestCase):
assert_(van.shape == (1, 5, 24))
-class TestCompanion(TestCase):
+class TestCompanion(object):
def test_raises(self):
assert_raises(ValueError, poly.polycompanion, [])
@@ -460,7 +461,7 @@ class TestCompanion(TestCase):
assert_(poly.polycompanion([1, 2])[0, 0] == -.5)
-class TestMisc(TestCase):
+class TestMisc(object):
def test_polyfromroots(self):
res = poly.polyfromroots([])