@@ -127,9 +127,7 @@ def test_transpose(self):
127
127
v = self .lazy_var
128
128
self .assertLazyAndIdentical (u .T , v .T )
129
129
130
- @pytest .mark .xfail (
131
- reason = "xarray uses np.pad which is not yet wired up to cubed.pad"
132
- )
130
+ @pytest .mark .xfail (reason = "needs pad mode='constant_values' in cubed" )
133
131
def test_shift (self ):
134
132
u = self .eager_var
135
133
v = self .lazy_var
@@ -193,10 +191,8 @@ def test_pickle(self):
193
191
def test_reduce (self ):
194
192
u = self .eager_var
195
193
v = self .lazy_var
196
- # TODO: remove skipna=False (https://github.com/cubed-dev/cubed/issues/153)
197
- self .assertLazyAndAllClose (u .mean (skipna = False ), v .mean (skipna = False ))
194
+ self .assertLazyAndAllClose (u .mean (), v .mean ())
198
195
# TODO: other reduce functions need work
199
- # self.assertLazyAndAllClose(u.mean(), v.mean())
200
196
# self.assertLazyAndAllClose(u.std(), v.std())
201
197
# with raise_if_cubed_computes():
202
198
# actual = v.argmax(dim="x")
@@ -345,7 +341,7 @@ def test_lazy_array(self):
345
341
self .assertLazyAndAllClose (u , v )
346
342
self .assertLazyAndAllClose (- u , - v )
347
343
self .assertLazyAndAllClose (u .T , v .T )
348
- # self.assertLazyAndAllClose(u.mean(), v.mean()) # TODO: isn't lazy
344
+ self .assertLazyAndAllClose (u .mean (), v .mean ())
349
345
self .assertLazyAndAllClose (1 + u , 1 + v )
350
346
351
347
actual = xr .concat ([v [:2 ], v [2 :]], "x" )
@@ -362,7 +358,6 @@ def test_compute(self):
362
358
363
359
assert ((u + 1 ).data == v2 .data ).all ()
364
360
365
- @pytest .mark .xfail (reason = "isn't lazy" )
366
361
def test_groupby (self ):
367
362
u = self .eager_array
368
363
v = self .lazy_array
@@ -372,7 +367,7 @@ def test_groupby(self):
372
367
actual = v .groupby ("x" ).mean (...)
373
368
self .assertLazyAndAllClose (expected , actual )
374
369
375
- @pytest .mark .xfail (reason = "isn't lazy " )
370
+ @pytest .mark .xfail (reason = "needs pad mode='constant_values' in cubed " )
376
371
def test_rolling (self ):
377
372
u = self .eager_array
378
373
v = self .lazy_array
0 commit comments