MCPcopy Index your code
hub / github.com/RustPython/RustPython / test_decode_surrogatepass

Method test_decode_surrogatepass

Lib/test/test_codecs.py:3831–3841  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

3829 self.check_decode_strings("surrogateescape")
3830
3831 def test_decode_surrogatepass(self):
3832 try:
3833 self.decode(b'', 'surrogatepass')
3834 except ValueError as exc:
3835 if str(exc) == 'unsupported error handler':
3836 self.skipTest(f"{self.ENCODING!r} decoder doesn't support "
3837 f"surrogatepass error handler")
3838 else:
3839 raise
3840
3841 self.check_decode_strings("surrogatepass")
3842
3843 def test_decode_unsupported_error_handler(self):
3844 with self.assertRaises(ValueError) as cm:

Callers

nothing calls this directly

Calls 4

decodeMethod · 0.95
check_decode_stringsMethod · 0.95
strFunction · 0.85
skipTestMethod · 0.80

Tested by

no test coverage detected