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

Unified Diff: Lib/test/test_json/test_scanstring.py

Issue 19361: Specialize exceptions thrown by JSON parser
Patch Set: Created 4 years, 9 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 | « Lib/test/test_json/test_fail.py ('k') | Modules/_json.c » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
--- a/Lib/test/test_json/test_scanstring.py Sun Nov 30 20:39:04 2014 +0200
+++ b/Lib/test/test_json/test_scanstring.py Mon Dec 01 00:17:14 2014 +0200
@@ -129,7 +129,7 @@ class TestScanstring:
'"\\ud834\\u0X20"',
]
for s in bad_escapes:
- with self.assertRaises(ValueError, msg=s):
+ with self.assertRaises(self.JSONDecodeError, msg=s):
scanstring(s, 1, True)
def test_overflow(self):
« no previous file with comments | « Lib/test/test_json/test_fail.py ('k') | Modules/_json.c » ('j') | no next file with comments »

RSS Feeds Recent Issues | This issue
This is Rietveld 894c83f36cb7+