diff --git a/.travis.yml b/.travis.yml index 247ff2d86..33aca5703 100644 --- a/.travis.yml +++ b/.travis.yml @@ -33,7 +33,7 @@ before_install: - conda install conda-build - conda config --add channels python-control - conda info -a - - conda create -q -n test-environment python="$TRAVIS_PYTHON_VERSION" pip coverage slycot + - conda create -q -n test-environment python="$TRAVIS_PYTHON_VERSION" pip coverage - source activate test-environment # coveralls not in conda repos - pip install coveralls @@ -45,6 +45,11 @@ install: # command to run tests script: + # Before installing Slycot + - python setup.py test + + # Now, get and use Slycot + - conda install slycot - coverage run setup.py test after_success: diff --git a/control/tests/modelsimp_test.py b/control/tests/modelsimp_test.py index c3e2296a7..f4bc0fd98 100644 --- a/control/tests/modelsimp_test.py +++ b/control/tests/modelsimp_test.py @@ -107,6 +107,7 @@ def testBalredTruncate(self): np.testing.assert_array_almost_equal(rsys.C, Crtrue,decimal=4) np.testing.assert_array_almost_equal(rsys.D, Drtrue,decimal=4) + @unittest.skipIf(not slycot_check(), "slycot not installed") def testBalredMatchDC(self): #controlable canonical realization computed in matlab for the transfer function: # num = [1 11 45 32], den = [1 15 60 200 60] diff --git a/control/tests/statefbk_test.py b/control/tests/statefbk_test.py index dbef9a915..34070aca7 100644 --- a/control/tests/statefbk_test.py +++ b/control/tests/statefbk_test.py @@ -71,6 +71,7 @@ def testGramWc(self): Wc = gram(sys,'c') np.testing.assert_array_almost_equal(Wc, Wctrue) + @unittest.skipIf(not slycot_check(), "slycot not installed") def testGramRc(self): A = np.matrix("1. -2.; 3. -4.") B = np.matrix("5. 6.; 7. 8.") @@ -103,6 +104,7 @@ def testGramWo2(self): Wo = gram(sys,'o') np.testing.assert_array_almost_equal(Wo, Wotrue) + @unittest.skipIf(not slycot_check(), "slycot not installed") def testGramRo(self): A = np.matrix("1. -2.; 3. -4.") B = np.matrix("5. 6.; 7. 8.")