(index)
| 641 | |
| 642 | @pytest.mark.parametrize("index", ([0, 2, 1], [0, 1, 1])) |
| 643 | def test_get_clean_interp_index_strict(index): |
| 644 | da = xr.DataArray([0, 1, 2], dims=("x",), coords={"x": index}) |
| 645 | |
| 646 | with pytest.raises(ValueError): |
| 647 | get_clean_interp_index(da, "x") |
| 648 | |
| 649 | clean = get_clean_interp_index(da, "x", strict=False) |
| 650 | np.testing.assert_array_equal(index, clean) |
| 651 | assert clean.dtype == np.float64 |
| 652 | |
| 653 | |
| 654 | @pytest.fixture |
nothing calls this directly
no test coverage detected
searching dependent graphs…