ó jš¤Mc@sNddlZddlmZddlZddlZdefd„ƒYZdS(iÿÿÿÿN(tTestCasetTestScanStringcBs5eZd„Zd„Zd„Zd„Zd„ZRS(cCs|jtjjƒdS(N(t_test_scanstringt simplejsontdecodert py_scanstring(tself((sS/opt/alt/python27/lib64/python2.7/site-packages/simplejson/tests/test_scanstring.pyttest_py_scanstringscCs'tjjsdS|jtjjƒdS(N(RRt c_scanstringR(R((sS/opt/alt/python27/lib64/python2.7/site-packages/simplejson/tests/test_scanstring.pyttest_c_scanstring s cCsÀ|j|dddtƒd<ƒtjdkrP|j|dddtƒd=ƒn|j|dddtƒd>ƒ|j|d ddtƒd?ƒ|j|d ddtƒd@ƒ|j|dddtƒdAƒ|j|dddtƒdBƒ|j|dddtƒdCƒ|j|dddtƒdDƒ|j|dddtƒdEƒ|j|dddtƒdFƒ|j|d ddtƒdGƒ|j|d#ddtƒdHƒ|j|d%ddtƒdIƒ|j|d'ddtƒdJƒ|j|d*ddtƒdKƒ|j|d,ddtƒdLƒ|j|d/ddtƒdMƒ|j|d1ddtƒdNƒ|j|d4ddtƒdOƒ|j|d7ddtƒdPƒ|j|d9ddtƒdQƒdS(RNs"z\ud834\udd20x"iuzð„ xiiÿÿu"zð„ x"iis"\u007b"u{is<"A JSON payload should be an object or array, not a string."u:A JSON payload should be an object or array, not a string.i<s["Unclosed array"iuUnclosed arrayis["extra comma",]u extra commais["double extra comma",,]udouble extra commais["Comma after the close"],uComma after the closeis["Extra close"]]u Extra closes{"Extra comma": true,}u Extra commas:{"Extra value after close": true} "misplaced quoted value"uExtra value after closeis{"Illegal expression": 1 + 2}uIllegal expressions{"Illegal invocation": alert()}uIllegal invocations+{"Numbers cannot have leading zeroes": 013}u"Numbers cannot have leading zeroesi%s{"Numbers cannot be hex": 0x14}uNumbers cannot be hexs2[[[[[[[[[[[[[[[[[[[["Too deep"]]]]]]]]]]]]]]]]]]]]uToo deepis{"Missing colon" null}u Missing colons{"Double colon":: null}u Double colonis {"Comma instead of colon", null}uComma instead of colonis!["Colon instead of comma": false]uColon instead of commas["Bad value", truth]u Bad valuei (uzð„ xi(uzð„ xi(uzð„ xi(u{i(u:A JSON payload should be an object or array, not a string.i<(uUnclosed arrayi(u extra commai(udouble extra commai(uComma after the closei(u Extra closei(u Extra commai(uExtra value after closei(uIllegal expressioni(uIllegal invocationi(u"Numbers cannot have leading zeroesi%(uNumbers cannot be hexi(uToo deepi(u Missing coloni(u Double coloni(uComma instead of coloni(uColon instead of commai(u Bad valuei (t assertEqualstNonetTruetsyst maxunicode(Rt scanstring((sS/opt/alt/python27/lib64/python2.7/site-packages/simplejson/tests/test_scanstring.pyRs† cCs<|jttjjdddƒ|jttjjdƒdS(Ntxxxisxxÿ(t assertRaisest ValueErrortjsonRRtUnicodeDecodeErrortencodertencode_basestring_ascii(R((sS/opt/alt/python27/lib64/python2.7/site-packages/simplejson/tests/test_scanstring.pyttest_issue3623js cCs9ttdtjƒ}|jttjjd|dƒdS(NtmaxsizeRi(tgetattrR tmaxintRt OverflowErrorRRR(RR((sS/opt/alt/python27/lib64/python2.7/site-packages/simplejson/tests/test_scanstring.pyt test_overflowps(t__name__t __module__RR RRR(((sS/opt/alt/python27/lib64/python2.7/site-packages/simplejson/tests/test_scanstring.pyRs    Z (R tunittestRRRtsimplejson.decoderR(((sS/opt/alt/python27/lib64/python2.7/site-packages/simplejson/tests/test_scanstring.pyts