Skip to content

Commit 19c2626

Browse files
authored
supress ambiguous reference date string warning (#4590)
1 parent 6c32d7c commit 19c2626

File tree

2 files changed

+2
-0
lines changed

2 files changed

+2
-0
lines changed

xarray/tests/test_coding_times.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -86,6 +86,7 @@ def _all_cftime_date_types():
8686

8787

8888
@requires_cftime
89+
@pytest.mark.filterwarnings("ignore:Ambiguous reference date string")
8990
@pytest.mark.parametrize(["num_dates", "units", "calendar"], _CF_DATETIME_TESTS)
9091
def test_cf_datetime(num_dates, units, calendar):
9192
import cftime

xarray/tests/test_conventions.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -233,6 +233,7 @@ def test_decode_cf_with_drop_variables(self):
233233
assert_identical(expected, actual)
234234
assert_identical(expected, actual2)
235235

236+
@pytest.mark.filterwarnings("ignore:Ambiguous reference date string")
236237
def test_invalid_time_units_raises_eagerly(self):
237238
ds = Dataset({"time": ("time", [0, 1], {"units": "foobar since 123"})})
238239
with raises_regex(ValueError, "unable to decode time"):

0 commit comments

Comments
 (0)