Skip to content

Commit

Permalink
Skipping 3 more tests if scipy is not available
Browse files Browse the repository at this point in the history
  • Loading branch information
emma58 committed Aug 6, 2024
1 parent 68b15a5 commit dabafbf
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions pyomo/contrib/piecewise/tests/test_nonlinear_to_pwl.py
Original file line number Diff line number Diff line change
Expand Up @@ -255,6 +255,7 @@ def test_error_for_non_separable_exceeding_max_dimension(self):
)

@unittest.skipUnless(numpy_available, "Numpy is not available")
@unittest.skipUnless(scipy_available, "Scipy is not available")
def test_do_not_additively_decompose_below_min_dimension(self):
m = ConcreteModel()
m.x = Var([0, 1, 2, 3, 4], bounds=(-4, 5))
Expand Down Expand Up @@ -317,6 +318,7 @@ def check_pw_linear_paraboloid(self, m, pwlf, x1, x2, y1, y2):
self.assertEqual(len(nonlinear), 0)

@unittest.skipUnless(numpy_available, "Numpy is not available")
@unittest.skipUnless(scipy_available, "Scipy is not available")
def test_paraboloid_objective_uniform_grid(self):
m = self.make_paraboloid_model()

Expand Down Expand Up @@ -344,6 +346,7 @@ def test_paraboloid_objective_uniform_grid(self):
self.check_pw_linear_paraboloid(m, pwlf, x1, x2, y1, y2)

@unittest.skipUnless(numpy_available, "Numpy is not available")
@unittest.skipUnless(scipy_available, "Scipy is not available")
def test_objective_target(self):
m = self.make_paraboloid_model()

Expand Down

0 comments on commit dabafbf

Please sign in to comment.