MCPcopy Index your code
hub / github.com/numpy/numpy / test_view

Method test_view

numpy/_core/tests/test_memmap.py:148–155  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

146 assert_(fp[:2, :2]._mmap is fp._mmap)
147
148 def test_view(self):
149 fp = memmap(self.tmpfp, dtype=self.dtype, shape=self.shape)
150 new1 = fp.view()
151 new2 = new1.view()
152 assert_(new1.base is fp)
153 assert_(new2.base is fp)
154 new_array = asarray(fp)
155 assert_(new_array.base is fp)
156
157 def test_ufunc_return_ndarray(self):
158 fp = memmap(self.tmpfp, dtype=self.dtype, shape=self.shape)

Callers

nothing calls this directly

Calls 4

memmapClass · 0.90
assert_Function · 0.90
asarrayFunction · 0.90
viewMethod · 0.45

Tested by

no test coverage detected