Skip to content

Commit

Permalink
tests: increase coverage
Browse files Browse the repository at this point in the history
  • Loading branch information
BradyPlanden committed Aug 27, 2024
1 parent 30b6101 commit 553d478
Showing 1 changed file with 13 additions and 0 deletions.
13 changes: 13 additions & 0 deletions tests/unit/test_optimisation.py
Original file line number Diff line number Diff line change
Expand Up @@ -421,6 +421,19 @@ def test_scipy_noprior(self, model, dataset):
):
opt.run()

@pytest.mark.unit
def test_scipy_bounds(self, cost):
# Create the optimisation class with incorrect bounds type
with pytest.raises(
TypeError,
match="Bounds provided must be either type dict, list or SciPy.optimize.bounds object.",
):
pybop.SciPyMinimize(
cost=cost,
bounds="This is a bad bound",
max_iterations=1,
)

@pytest.mark.unit
def test_halting(self, cost):
# Test max evalutions
Expand Down

0 comments on commit 553d478

Please sign in to comment.