Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix test_doc_example on big-endian systems #9949

Merged
merged 1 commit into from
Jan 23, 2025
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 6 additions & 2 deletions xarray/tests/test_datatree.py
Original file line number Diff line number Diff line change
Expand Up @@ -1240,8 +1240,12 @@ def test_repr_inherited_dims(self) -> None:
)
def test_doc_example(self) -> None:
# regression test for https://github.com/pydata/xarray/issues/9499
time = xr.DataArray(data=["2022-01", "2023-01"], dims="time")
stations = xr.DataArray(data=list("abcdef"), dims="station")
time = xr.DataArray(
data=np.array(["2022-01", "2023-01"], dtype="<U7"), dims="time"
)
stations = xr.DataArray(
data=np.array(list("abcdef"), dtype="<U1"), dims="station"
)
lon = [-100, -80, -60]
lat = [10, 20, 30]
# Set up fake data
Expand Down
Loading