(self)
| 139 | assert_array_equal(result, expected) |
| 140 | |
| 141 | def test_subclass(self): |
| 142 | class MinimalSubclass(np.ndarray): |
| 143 | data = 1 |
| 144 | |
| 145 | def minimal_function(array): |
| 146 | return array.data |
| 147 | |
| 148 | a = np.zeros((6, 3)).view(MinimalSubclass) |
| 149 | |
| 150 | assert_array_equal( |
| 151 | apply_along_axis(minimal_function, 0, a), np.array([1, 1, 1]) |
| 152 | ) |
| 153 | |
| 154 | def test_scalar_array(self, cls=np.ndarray): |
| 155 | a = np.ones((6, 3)).view(cls) |
nothing calls this directly
no test coverage detected