diff --git a/slycot/tests/test_ab01.py b/slycot/tests/test_ab01.py index ec544b13..01c1242b 100644 --- a/slycot/tests/test_ab01.py +++ b/slycot/tests/test_ab01.py @@ -6,7 +6,6 @@ from numpy import array from numpy.testing import assert_allclose, assert_equal - from scipy.linalg.lapack import dorgqr from slycot.analysis import ab01nd diff --git a/slycot/tests/test_ab04md.py b/slycot/tests/test_ab04md.py index 076c4a6c..bafee439 100644 --- a/slycot/tests/test_ab04md.py +++ b/slycot/tests/test_ab04md.py @@ -1,8 +1,8 @@ -from slycot import analysis import numpy as np - from numpy.testing import assert_allclose +from slycot import analysis + class Test_ab04md: """Test ab04md. diff --git a/slycot/tests/test_ab08n.py b/slycot/tests/test_ab08n.py index 130ae95d..c777fc07 100644 --- a/slycot/tests/test_ab08n.py +++ b/slycot/tests/test_ab08n.py @@ -1,11 +1,11 @@ # =================================================== # ab08n* tests -from slycot import analysis import numpy as np - +from numpy.testing import assert_allclose, assert_equal from scipy.linalg import eig -from numpy.testing import assert_equal, assert_allclose + +from slycot import analysis class Test_ab08nX: diff --git a/slycot/tests/test_ab13bd.py b/slycot/tests/test_ab13bd.py index db4a2bd7..dd2a735a 100644 --- a/slycot/tests/test_ab13bd.py +++ b/slycot/tests/test_ab13bd.py @@ -1,12 +1,12 @@ # =================================================== # ab08n* tests -from slycot import analysis import numpy as np +from numpy.testing import assert_allclose, assert_array_equal, assert_equal +from scipy import linalg, signal + +from slycot import analysis -from scipy import linalg -from scipy import signal -from numpy.testing import assert_equal, assert_allclose, assert_array_equal class Test_ab13bd: """ Test regular pencil construction ab08nX with input parameters diff --git a/slycot/tests/test_ab13md.py b/slycot/tests/test_ab13md.py index df69a6b3..5a30f5ba 100644 --- a/slycot/tests/test_ab13md.py +++ b/slycot/tests/test_ab13md.py @@ -1,7 +1,6 @@ import numpy as np -from numpy.testing import assert_allclose, assert_array_less - import pytest +from numpy.testing import assert_allclose, assert_array_less from slycot import ab13md diff --git a/slycot/tests/test_ag08bd.py b/slycot/tests/test_ag08bd.py index e849cef4..97aa2b41 100644 --- a/slycot/tests/test_ag08bd.py +++ b/slycot/tests/test_ag08bd.py @@ -1,10 +1,10 @@ """Verify ag08bd with input parameters according to example in documentation.""" -from slycot import analysis import numpy as np - from numpy.testing import assert_almost_equal, assert_equal +from slycot import analysis + # test1 input parameters test1_l = 9 diff --git a/slycot/tests/test_analysis.py b/slycot/tests/test_analysis.py index 701eab4a..0b899580 100644 --- a/slycot/tests/test_analysis.py +++ b/slycot/tests/test_analysis.py @@ -3,10 +3,12 @@ # repagh , Aug 2019 -import pytest import re +import pytest + from slycot import mc01td from slycot.exceptions import SlycotResultWarning diff --git a/slycot/tests/test_sb.py b/slycot/tests/test_sb.py index 00e406db..e6f97a07 100644 --- a/slycot/tests/test_sb.py +++ b/slycot/tests/test_sb.py @@ -1,14 +1,14 @@ # =================================================== # sb* synthesis tests -from slycot import synthesis -from slycot.exceptions import raise_if_slycot_error, \ - SlycotParameterError, SlycotArithmeticError, \ - SlycotResultWarning - +import pytest from numpy import array, eye, zeros from numpy.testing import assert_allclose, assert_raises -import pytest + +from slycot import synthesis +from slycot.exceptions import (SlycotArithmeticError, SlycotParameterError, + SlycotResultWarning, raise_if_slycot_error) + from .test_exceptions import assert_docstring_parse diff --git a/slycot/tests/test_sg02ad.py b/slycot/tests/test_sg02ad.py index d640b159..1576a8ec 100644 --- a/slycot/tests/test_sg02ad.py +++ b/slycot/tests/test_sg02ad.py @@ -2,11 +2,12 @@ # test_sg02ad.py - test suite for ricatti equation solving # RvP, 19 Jun 2017 -from slycot import synthesis import numpy as np - from numpy.testing import assert_almost_equal +from slycot import synthesis + + def test_sg02ad_case1(): n = 3 m = 1 diff --git a/slycot/tests/test_sg03ad.py b/slycot/tests/test_sg03ad.py index 1352ebb8..a5976e0d 100644 --- a/slycot/tests/test_sg03ad.py +++ b/slycot/tests/test_sg03ad.py @@ -2,11 +2,11 @@ # test_sg03ad.py - test suite for stability margin commands # RvP, 15 Jun 2017 -from slycot import synthesis import numpy as np - from numpy.testing import assert_almost_equal +from slycot import synthesis + # test cases from # Penzl T., Numerical Solution of Generalized Lyapunov Equations # http://www.qucosa.de/fileadmin/data/qucosa/documents/4168/data/b002.pdf diff --git a/slycot/tests/test_tb05ad.py b/slycot/tests/test_tb05ad.py index b5a1d3e3..900a49a2 100644 --- a/slycot/tests/test_tb05ad.py +++ b/slycot/tests/test_tb05ad.py @@ -3,10 +3,10 @@ import sys -import pytest import numpy as np -from scipy.linalg import matrix_balance, eig +import pytest from numpy.testing import assert_almost_equal +from scipy.linalg import eig, matrix_balance from slycot import transform from slycot.exceptions import SlycotArithmeticError, SlycotParameterError diff --git a/slycot/tests/test_tg01ad.py b/slycot/tests/test_tg01ad.py index db9479aa..864d41be 100644 --- a/slycot/tests/test_tg01ad.py +++ b/slycot/tests/test_tg01ad.py @@ -1,10 +1,10 @@ # =================================================== # tg01ad tests -from slycot import transform import numpy as np +from numpy.testing import assert_almost_equal, assert_equal, assert_raises -from numpy.testing import assert_raises, assert_almost_equal, assert_equal +from slycot import transform # test1 input parameters diff --git a/slycot/tests/test_tg01fd.py b/slycot/tests/test_tg01fd.py index 70ebef19..902d1ef2 100644 --- a/slycot/tests/test_tg01fd.py +++ b/slycot/tests/test_tg01fd.py @@ -1,10 +1,10 @@ # =================================================== # tg01fd tests -from slycot import transform import numpy as np +from numpy.testing import assert_almost_equal, assert_equal, assert_raises -from numpy.testing import assert_raises, assert_almost_equal, assert_equal +from slycot import transform # test1 input parameters test1_l = 4 diff --git a/slycot/tests/test_transform.py b/slycot/tests/test_transform.py index fa22c514..928ac5d4 100644 --- a/slycot/tests/test_transform.py +++ b/slycot/tests/test_transform.py @@ -3,10 +3,12 @@ # repagh