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

Method test_show_caches_with_label

Lib/test/test_dis.py:2117–2127  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

2115 self.assertEqual(instruction.arg, instruction.oparg)
2116
2117 def test_show_caches_with_label(self):
2118 def f(x, y, z):
2119 if x:
2120 res = y
2121 else:
2122 res = z
2123 return res
2124
2125 output = io.StringIO()
2126 dis.dis(f.__code__, file=output, show_caches=True)
2127 self.assertIn("L1:", output.getvalue())
2128
2129 def test_is_op_format(self):
2130 output = io.StringIO()

Callers

nothing calls this directly

Calls 3

getvalueMethod · 0.95
disMethod · 0.80
assertInMethod · 0.80

Tested by

no test coverage detected