MCPcopy
hub / github.com/pydata/xarray / test_encode_expected_failures

Function test_encode_expected_failures

xarray/tests/test_coding_times.py:886–891  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

884
885
886def test_encode_expected_failures() -> None:
887 dates = pd.date_range("2000", periods=3)
888 with pytest.raises(ValueError, match="invalid time units"):
889 encode_cf_datetime(dates, units="days after 2000-01-01")
890 with pytest.raises(ValueError, match="invalid reference date"):
891 encode_cf_datetime(dates, units="days since NO_YEAR")
892
893
894def test_encode_cf_datetime_pandas_min() -> None:

Callers

nothing calls this directly

Calls 1

encode_cf_datetimeFunction · 0.90

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…