MCPcopy Create free account
hub / github.com/simplejson/simplejson / test_encoding2

Method test_encoding2

simplejson/tests/test_unicode.py:17–22  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

15 self.assertEqual(ju, js)
16
17 def test_encoding2(self):
18 u = u'\N{GREEK SMALL LETTER ALPHA}\N{GREEK CAPITAL LETTER OMEGA}'
19 s = u.encode('utf-8')
20 ju = json.dumps(u, encoding='utf-8')
21 js = json.dumps(s, encoding='utf-8')
22 self.assertEqual(ju, js)
23
24 def test_encoding3(self):
25 u = u'\N{GREEK SMALL LETTER ALPHA}\N{GREEK CAPITAL LETTER OMEGA}'

Callers

nothing calls this directly

Calls 2

dumpsMethod · 0.80
encodeMethod · 0.45

Tested by

no test coverage detected