Test comparing arrays with NaNs.
()
| 477 | |
| 478 | |
| 479 | def test_array_equal_nan(): |
| 480 | """Test comparing arrays with NaNs.""" |
| 481 | a = b = [1, np.nan, 0] |
| 482 | assert not np.array_equal(a, b) # this is the annoying behavior we avoid |
| 483 | assert _array_equal_nan(a, b) |
| 484 | b = [np.nan, 1, 0] |
| 485 | assert not _array_equal_nan(a, b) |
| 486 | a = b = [np.nan] * 2 |
| 487 | assert _array_equal_nan(a, b) |
| 488 | |
| 489 | |
| 490 | def test_julian_conversions(): |
nothing calls this directly
no test coverage detected