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

Method test_file_with_missing_final_nl

Lib/test/test_cmd.py:223–232  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

221
222
223 def test_file_with_missing_final_nl(self):
224 input = io.StringIO("print test\nprint test2")
225 output = io.StringIO()
226 cmd = self.simplecmd(stdin=input, stdout=output)
227 cmd.use_rawinput = False
228 cmd.cmdloop()
229 self.assertMultiLineEqual(output.getvalue(),
230 ("(Cmd) test\n"
231 "(Cmd) test2\n"
232 "(Cmd) "))
233
234
235 def test_input_reset_at_EOF(self):

Callers

nothing calls this directly

Calls 3

getvalueMethod · 0.95
assertMultiLineEqualMethod · 0.80
cmdloopMethod · 0.45

Tested by

no test coverage detected