Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code | Sign in
(2533)

Unified Diff: Lib/test/test_cmd_line.py

Issue 10206: python program starting with unmatched quote spews spaces to stdout
Patch Set: Created 1 year, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Please Sign in to add in-line comments.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
--- a/Lib/test/test_cmd_line.py Thu Jun 23 21:26:48 2011 -0400
+++ b/Lib/test/test_cmd_line.py Fri Jun 24 18:15:30 2011 +0200
@@ -259,6 +259,13 @@
"print(repr(input()))",
b"'abc'")
+ def test_unmached_quote(self):
+ # Issue #10206: python program starting with unmatched quote
+ # spews spaces to stdout
+ rc, out, err = assert_python_failure('-c', "'")
+ self.assertRegex(err.decode('ascii', 'ignore'), 'SyntaxError')
+ self.assertEqual(b'', out)
+
def test_main():
test.support.run_unittest(CmdLineTest)
« no previous file with comments | « no previous file | no next file » | no next file with comments »

RSS Feeds Recent Issues | This issue
This is Rietveld cbc36f91f3f7