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

Method test_nofile

numpy/_core/tests/test_multiarray.py:6107–6113  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

6105 return request.param
6106
6107 def test_nofile(self):
6108 # this should probably be supported as a file
6109 # but for now test for proper errors
6110 b = io.BytesIO()
6111 assert_raises(OSError, np.fromfile, b, np.uint8, 80)
6112 d = np.ones(7)
6113 assert_raises(OSError, lambda x: x.tofile(b), d)
6114
6115 def test_bool_fromstring(self):
6116 v = np.array([True, False, True, False], dtype=np.bool)

Callers

nothing calls this directly

Calls 2

assert_raisesFunction · 0.90
tofileMethod · 0.80

Tested by

no test coverage detected