MCPcopy Index your code
hub / github.com/RustPython/RustPython / test_tolist

Method test_tolist

Lib/test/test_memoryview.py:195–199  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

193 self.assertIsInstance(b, bytes)
194
195 def test_tolist(self):
196 for tp in self._types:
197 m = self._view(tp(self._source))
198 l = m.tolist()
199 self.assertEqual(l, list(b"abcdef"))
200
201 def test_compare(self):
202 # memoryviews can compare for equality with other objects

Callers

nothing calls this directly

Calls 4

listClass · 0.85
_viewMethod · 0.45
tolistMethod · 0.45
assertEqualMethod · 0.45

Tested by

no test coverage detected