(self)
| 502 | assert_array_equal(arr, np.array([0, 3, 2, 3, 4])) |
| 503 | |
| 504 | def test_subok(self): |
| 505 | class MyArray(np.ndarray): |
| 506 | pass |
| 507 | |
| 508 | arr = np.arange(5).view(MyArray) |
| 509 | assert_(not isinstance(sliding_window_view(arr, 2, |
| 510 | subok=False), |
| 511 | MyArray)) |
| 512 | assert_(isinstance(sliding_window_view(arr, 2, subok=True), MyArray)) |
| 513 | # Default behavior |
| 514 | assert_(not isinstance(sliding_window_view(arr, 2), MyArray)) |
| 515 | |
| 516 | |
| 517 | def as_strided_writeable(): |
nothing calls this directly
no test coverage detected