Example #1
0
 def test_support_surrogates(self):
     assert bytes_to_str(u'\ud83d\ude4f') == u'\ud83d\ude4f'
Example #2
0
 def test_from_unicode(self):
     assert isinstance(bytes_to_str(u'foo'), text_t)
Example #3
0
 def test_from_bytes(self):
     assert bytes_to_str(b'foo')
Example #4
0
 def test_from_bytes(self):
     assert bytes_to_str(b'foo')
Example #5
0
 def test_support_surrogates(self):
     assert bytes_to_str(u'\ud83d\ude4f') == u'\ud83d\ude4f'
Example #6
0
 def test_from_unicode(self):
     assert isinstance(bytes_to_str(u'foo'), text_t)
Example #7
0
 def test_from_unicode(self):
     assert isinstance(bytes_to_str('foo'), str)
Example #8
0
 def test_from_bytes(self):
     self.assertTrue(bytes_to_str(b'foo'))
Example #9
0
 def test_from_unicode(self):
     self.assertIsInstance(bytes_to_str('foo'), text_t)
Example #10
0
 def test_from_bytes(self):
     self.assertTrue(bytes_to_str(b'foo'))
Example #11
0
 def test_from_unicode(self):
     self.assertIsInstance(bytes_to_str('foo'), text_t)
Example #12
0
 def test_from_unicode(self):
     assert isinstance(bytes_to_str('foo'), str)