MCPcopy Index your code
hub / github.com/python/cpython / test_memoryview_hex

Method test_memoryview_hex

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

Source from the content-addressed store, hash-verified

703 self.assertListEqual(float_complex_view.tolist(), double_complex_view.tolist())
704
705 def test_memoryview_hex(self):
706 # Issue #9951: memoryview.hex() segfaults with non-contiguous buffers.
707 x = b'0' * 200000
708 m1 = memoryview(x)
709 m2 = m1[::-1]
710 self.assertEqual(m2.hex(), '30' * 200000)
711
712 def test_memoryview_hex_separator(self):
713 x = bytes(range(97, 102))

Callers

nothing calls this directly

Calls 2

assertEqualMethod · 0.45
hexMethod · 0.45

Tested by

no test coverage detected