Skip to content

Commit

Permalink
fix tests, somehow
Browse files Browse the repository at this point in the history
  • Loading branch information
stephenworsley committed Feb 27, 2025
1 parent 31dd165 commit 133e03d
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lib/iris/tests/unit/analysis/test_PERCENTILE.py
Original file line number Diff line number Diff line change
Expand Up @@ -162,7 +162,7 @@ def test_default_kwargs_passed(self, mocked_mquantiles):
for key in ["alphap", "betap"]:
self.assertEqual(mocked_mquantiles.call_args.kwargs[key], 1)

@mock.patch("scipy.stats.mstats.mquantiles")
@mock.patch("scipy.stats.mstats.mquantiles", return_value=np.array([2, 4]))
def test_chosen_kwargs_passed(self, mocked_mquantiles):
data = np.arange(5)
percent = [42, 75]
Expand Down Expand Up @@ -356,7 +356,7 @@ def test_numpy_percentile_called(self, mocked_percentile):
# Check we have left "method" keyword to numpy's default.
self.assertNotIn("method", mocked_percentile.call_args.kwargs)

@mock.patch("numpy.percentile")
@mock.patch("numpy.percentile", return_value=np.array([2, 4]))
def test_chosen_method_kwarg_passed(self, mocked_percentile):
data = da.arange(5)
percent = [42, 75]
Expand Down

0 comments on commit 133e03d

Please sign in to comment.