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

Method test_run_code

Lib/test/test_cmd_line.py:233–240  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

231 assert_python_ok('-m', 'unittest', "./test/test_longexp.py")
232
233 def test_run_code(self):
234 # Test expected operation of the '-c' switch
235 # Switch needs an argument
236 assert_python_failure('-c')
237 # Check we get an error for an uncaught exception
238 assert_python_failure('-c', 'raise Exception')
239 # All good if execution is successful
240 assert_python_ok('-c', 'pass')
241
242 @unittest.skipUnless(os_helper.FS_NONASCII, 'need os_helper.FS_NONASCII')
243 def test_non_ascii(self):

Callers

nothing calls this directly

Calls 2

assert_python_failureFunction · 0.90
assert_python_okFunction · 0.90

Tested by

no test coverage detected