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

Function test_dayofyear_after_cftime

xarray/tests/test_cftime_offsets.py:1391–1396  ·  view source on GitHub ↗
(freq: str)

Source from the content-addressed store, hash-verified

1389
1390@pytest.mark.parametrize("freq", ["YE", "ME", "D"])
1391def test_dayofyear_after_cftime(freq: str) -> None:
1392 result = date_range("2000-02-01", periods=3, freq=freq, use_cftime=True).dayofyear
1393 # TODO: remove once requiring pandas 2.2+
1394 freq = _new_to_legacy_freq(freq)
1395 expected = pd.date_range("2000-02-01", periods=3, freq=freq).dayofyear
1396 np.testing.assert_array_equal(result, expected)
1397
1398
1399def test_cftime_range_standard_calendar_refers_to_gregorian() -> None:

Callers

nothing calls this directly

Calls 2

date_rangeFunction · 0.90
_new_to_legacy_freqFunction · 0.90

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…