MCPcopy Index your code
hub / github.com/ipython/ipython / test_get_output_error_code

Method test_get_output_error_code

tests/test_process.py:228–237  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

226 self.assertEqual(err, "on stderr")
227
228 def test_get_output_error_code(self):
229 quiet_exit = '%s -c "import sys; sys.exit(1)"' % python
230 out, err, code = get_output_error_code(quiet_exit)
231 self.assertEqual(out, "")
232 self.assertEqual(err, "")
233 self.assertEqual(code, 1)
234 out, err, code = get_output_error_code(f'{python} "{self.fname}"')
235 self.assertEqual(out, "on stdout")
236 self.assertEqual(err, "on stderr")
237 self.assertEqual(code, 0)

Callers

nothing calls this directly

Calls 1

get_output_error_codeFunction · 0.90

Tested by

no test coverage detected