Message297951
The possible test:
import unittest
from json.decoder import JSONDecoder
class Memo_Test(unittest.TestCase):
def test_for_empty_memo(self):
json_str = '{"a": 1}'
decoder = JSONDecoder()
decoder.decode(json_str)
self.assertEqual(decoder.memo, {})
suite = unittest.TestSuite()
suite.addTest(Memo_Test("test_for_empty_memo"))
runner = unittest.TextTestRunner()
runner.run(suite)
But it works only when _json import fails |
|
Date |
User |
Action |
Args |
2017-07-08 08:40:42 | c-fos | set | recipients:
+ c-fos, pitrou, serhiy.storchaka |
2017-07-08 08:40:42 | c-fos | set | messageid: <1499503242.93.0.727725151692.issue30877@psf.upfronthosting.co.za> |
2017-07-08 08:40:42 | c-fos | link | issue30877 messages |
2017-07-08 08:40:42 | c-fos | create | |
|