Skip to content

Commit

Permalink
xfail pyarrow test (#8635)
Browse files Browse the repository at this point in the history
* xfail pyarrow test

Sorry for the repeated PR -- some tests passed but some failed without pyarrow installed. So this xfails the test for the moment
  • Loading branch information
max-sixty authored Jan 21, 2024
1 parent a913cfe commit f4ed09d
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions xarray/tests/test_dask.py
Original file line number Diff line number Diff line change
Expand Up @@ -812,6 +812,10 @@ def test_to_dask_dataframe(self):
assert isinstance(actual, dd.DataFrame)
assert_frame_equal(actual.compute(), expected.compute())

@pytest.mark.xfail(
reason="Currently pandas with pyarrow installed will return a `string[pyarrow]` type, "
"which causes the `y` column to have a different type depending on whether pyarrow is installed"
)
def test_to_dask_dataframe_2D(self):
# Test if 2-D dataset is supplied
w = np.random.randn(2, 3)
Expand All @@ -830,10 +834,6 @@ def test_to_dask_dataframe_2D(self):
actual = ds.to_dask_dataframe(set_index=False)

assert isinstance(actual, dd.DataFrame)
# TOOD: not sure if this is the correct behavior, but currently pandas with
# pyarrow installed will return a `string[pyarrow]` type, so matching that until
# we can fix the underlying issue
expected["y"] = expected["y"].astype("string[pyarrow]")
assert_frame_equal(actual.compute(), expected)

@pytest.mark.xfail(raises=NotImplementedError)
Expand Down

0 comments on commit f4ed09d

Please sign in to comment.