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

Method test_without_pos

Lib/test/test_pickletools.py:115–125  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

113 self.assertEqual(f.read(), b'suffix')
114
115 def test_without_pos(self):
116 f = SimpleReader(b'(I123\nK\x12J\x12\x34\x56\x78t.')
117 it = pickletools.genops(f)
118 self.assertEqual([(item[0].name,) + item[1:] for item in it], [
119 ('MARK', None, None),
120 ('INT', 123, None),
121 ('BININT1', 0x12, None),
122 ('BININT', 0x78563412, None),
123 ('TUPLE', None, None),
124 ('STOP', None, None),
125 ])
126
127 def test_no_stop(self):
128 it = pickletools.genops(b'N')

Callers

nothing calls this directly

Calls 2

SimpleReaderClass · 0.70
assertEqualMethod · 0.45

Tested by

no test coverage detected