(da_time, max_gap, transform, use_cftime)
| 689 | "max_gap", ["3h", np.timedelta64(3, "h"), pd.to_timedelta("3h")] |
| 690 | ) |
| 691 | def test_interpolate_na_max_gap_time_specifier(da_time, max_gap, transform, use_cftime): |
| 692 | da_time["t"] = xr.date_range( |
| 693 | "2001-01-01", freq="h", periods=11, use_cftime=use_cftime |
| 694 | ) |
| 695 | expected = transform( |
| 696 | da_time.copy(data=[np.nan, 1, 2, 3, 4, 5, np.nan, np.nan, np.nan, np.nan, 10]) |
| 697 | ) |
| 698 | actual = transform(da_time).interpolate_na("t", max_gap=max_gap) |
| 699 | assert_allclose(actual, expected) |
| 700 | |
| 701 | |
| 702 | @requires_bottleneck |
nothing calls this directly
no test coverage detected
searching dependent graphs…