From d7f677ccb5a513b2ea755f03318c7f0d680df4c0 Mon Sep 17 00:00:00 2001 From: dcherian Date: Sat, 9 Nov 2019 11:45:51 -0700 Subject: [PATCH] fix tests. --- xarray/tests/test_dataset.py | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/xarray/tests/test_dataset.py b/xarray/tests/test_dataset.py index 449c40d8424..2a92d7f7730 100644 --- a/xarray/tests/test_dataset.py +++ b/xarray/tests/test_dataset.py @@ -5402,12 +5402,11 @@ def test_coarsen(ds, dask, boundary, side): actual = ds.coarsen(time=2, x=3, boundary=boundary, side=side).max() assert_equal( - actual["z1"], ds["z1"].coarsen(time=2, x=3, boundary=boundary, side=side).max() + actual["z1"], ds["z1"].coarsen(x=3, boundary=boundary, side=side).max() ) # coordinate should be mean by default assert_equal( - actual["time"], - ds["time"].coarsen(time=2, x=3, boundary=boundary, side=side).mean(), + actual["time"], ds["time"].coarsen(time=2, boundary=boundary, side=side).mean() ) @@ -5418,8 +5417,8 @@ def test_coarsen_coords(ds, dask): # check if coord_func works actual = ds.coarsen(time=2, x=3, boundary="trim", coord_func={"time": "max"}).max() - assert_equal(actual["z1"], ds["z1"].coarsen(time=2, x=3, boundary="trim").max()) - assert_equal(actual["time"], ds["time"].coarsen(time=2, x=3, boundary="trim").max()) + assert_equal(actual["z1"], ds["z1"].coarsen(x=3, boundary="trim").max()) + assert_equal(actual["time"], ds["time"].coarsen(time=2, boundary="trim").max()) # raise if exact with pytest.raises(ValueError):