(self)
| 312 | self.fail("Should have raised SourceNotFound") |
| 313 | |
| 314 | def test_current_function(self): |
| 315 | self.set_input_line("INPUTLINE") |
| 316 | self.repl.current_func = inspect.getsource |
| 317 | self.assertIn( |
| 318 | "text of the source code", self.repl.get_source_of_current_name() |
| 319 | ) |
| 320 | |
| 321 | self.assert_get_source_error_for_current_function( |
| 322 | [], "No source code found for INPUTLINE" |
| 323 | ) |
| 324 | |
| 325 | self.assert_get_source_error_for_current_function( |
| 326 | list.pop, "No source code found for INPUTLINE" |
| 327 | ) |
| 328 | |
| 329 | @unittest.skipIf(pypy, "different errors for PyPy") |
| 330 | def test_current_function_cpython(self): |
nothing calls this directly
no test coverage detected