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

Method test_show_code

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

Source from the content-addressed store, hash-verified

1649
1650 @unittest.expectedFailure # TODO: RUSTPYTHON
1651 def test_show_code(self):
1652 self.maxDiff = 1000
1653 for x, expected in self.test_pairs:
1654 with captured_stdout() as output:
1655 dis.show_code(x)
1656 self.assertRegex(output.getvalue(), expected+"\n")
1657 output = io.StringIO()
1658 dis.show_code(x, file=output)
1659 self.assertRegex(output.getvalue(), expected)
1660
1661 def test_code_info_object(self):
1662 self.assertRaises(TypeError, dis.code_info, object())

Callers

nothing calls this directly

Calls 3

getvalueMethod · 0.95
captured_stdoutFunction · 0.90
assertRegexMethod · 0.80

Tested by

no test coverage detected