From 10b68c33b1806d3a4be5e6fc3031962b1299a036 Mon Sep 17 00:00:00 2001 From: Elliott Sales de Andrade Date: Wed, 22 Jan 2025 21:41:18 -0500 Subject: [PATCH] Fix test_doc_example on big-endian systems (#9949) ... by using a fixed-endian input. --- xarray/tests/test_datatree.py | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/xarray/tests/test_datatree.py b/xarray/tests/test_datatree.py index 7b295128d63..21870050034 100644 --- a/xarray/tests/test_datatree.py +++ b/xarray/tests/test_datatree.py @@ -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="