Skip to content
forked from pydata/xarray

Commit

Permalink
Test one more warning
Browse files Browse the repository at this point in the history
  • Loading branch information
dcherian committed Dec 2, 2023
1 parent bf8139d commit a57d4ae
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion xarray/tests/test_groupby.py
Original file line number Diff line number Diff line change
Expand Up @@ -199,7 +199,8 @@ def func(arg1, arg2, arg3=0):

array = xr.DataArray([1, 1, 1], [("x", [1, 2, 3])])
expected = xr.DataArray([3, 3, 3], [("x", [1, 2, 3])])
actual = array.groupby("x", squeeze=False).map(func, args=(1,), arg3=1)
with pytest.warns(UserWarning, match="The `squeeze` kwarg"):
actual = array.groupby("x").map(func, args=(1,), arg3=1)
assert_identical(expected, actual)


Expand Down

0 comments on commit a57d4ae

Please sign in to comment.