Skip to content

Commit

Permalink
Make test for JuMP variables conditional on presence of JuMP
Browse files Browse the repository at this point in the history
  • Loading branch information
jezsadler authored Apr 20, 2024
1 parent cad7ba2 commit 3abb7ff
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion tests/test_block.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,8 @@

from omlt import OmltBlock
from omlt.base import OmltVar
from omlt.dependencies import julia_available



class dummy_formulation(object):
Expand Down Expand Up @@ -40,7 +42,9 @@ def test_block():
assert [k for k in m.b.inputs] == ["A", "C", "D"]
assert [k for k in m.b.outputs] == [(0, 0), (0, 1), (1, 0), (1, 1)]


@pytest.mark.skipif(
not julia_available, reason="Test only valid when Julia is available"
)
def test_jump_block():
m = pyo.ConcreteModel()
m.b = OmltBlock()
Expand Down

0 comments on commit 3abb7ff

Please sign in to comment.