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

Method test_tolist

Lib/test/test_array.py:1869–1874  ·  view source on GitHub ↗
(self, size)

Source from the content-addressed store, hash-verified

1867 # list takes about 9 bytes per element
1868 @support.bigmemtest(_2G, memuse=2.125+9)
1869 def test_tolist(self, size):
1870 example = self.example(size)
1871 ls = example.tolist()
1872 self.assertEqual(len(ls), len(example))
1873 self.assertEqual(ls[:8], list(example[:8]))
1874 self.assertEqual(ls[-8:], list(example[-8:]))
1875
1876 def test_gh_128961(self):
1877 a = array.array('i')

Callers

nothing calls this directly

Calls 5

exampleMethod · 0.95
lenFunction · 0.85
listClass · 0.85
tolistMethod · 0.45
assertEqualMethod · 0.45

Tested by

no test coverage detected