Test making sure we properly fall back to cftime on abbreviated units.
()
| 454 | |
| 455 | @requires_cftime |
| 456 | def test_decode_abbreviation() -> None: |
| 457 | """Test making sure we properly fall back to cftime on abbreviated units.""" |
| 458 | import cftime |
| 459 | |
| 460 | val = np.array([1586628000000.0]) |
| 461 | units = "msecs since 1970-01-01T00:00:00Z" |
| 462 | actual = decode_cf_datetime(val, units) |
| 463 | expected = cftime_to_nptime(cftime.num2date(val, units)) |
| 464 | assert_array_equal(actual, expected) |
| 465 | |
| 466 | |
| 467 | @arm_xfail |
nothing calls this directly
no test coverage detected
searching dependent graphs…