diff --git a/tests/test_general.py b/tests/test_general.py index 1d0fa3c..0db0ca6 100644 --- a/tests/test_general.py +++ b/tests/test_general.py @@ -3,6 +3,7 @@ from stickydesign import endarray import pytest import numpy as np +from stickydesign.energetics_basic import ACCEL @pytest.fixture() def sets_daoe(): @@ -25,7 +26,7 @@ def en_daoe(): return energetics_daoe.EnergeticsDAOE() @pytest.fixture() -@pytest.mark.skip(reason="Disabled old acceleration.") +@pytest.mark.skipif(not ACCEL, reason="No acceleration available.") def en_basicold(): from stickydesign import energetics_basic_old return energetics_basic_old.EnergeticsBasicOld() @@ -61,7 +62,7 @@ def test_basic_symmetry(sets_basic, en_basic): r2 = en_basic.uniform(s[50:], s[:50]) np.testing.assert_array_almost_equal(r1, r2) -@pytest.mark.skip(reason="Disabled old acceleration.") +@pytest.mark.skipif(not ACCEL, reason="No acceleration available.") def test_basic_old_matching_energies_match(sets_daoe, en_basicold): for s in sets_daoe: r1 = en_basicold.matching_uniform(s) @@ -71,7 +72,7 @@ def test_basic_old_matching_energies_match(sets_daoe, en_basicold): np.testing.assert_array_almost_equal(r1, r2) np.testing.assert_array_almost_equal(r1, r3) -@pytest.mark.skip(reason="Disabled old acceleration.") +@pytest.mark.skipif(not ACCEL, reason="No acceleration available.") def test_basic_old_symmetry(sets_daoe, en_basicold): for s in sets_daoe: r1 = en_basicold.uniform(s[:50], s[50:])