a ze¶ã@sPdZddlZddlZdd„Ze e¡dZGdd„dejƒZedkrLe  ¡dS) zá Python character mapping codec test This uses the test codec in testcodec.py and thus also tests the encodings package lookup scheme. Written by Marc-Andre Lemburg (mal@lemburg.com). (c) Copyright 2000 Guido van Rossum. éNcCs$|dkr ddlm}t| ¡ƒSdS)NÚ testcodecr)r)ÚtestrÚtupleÚ getregentry)Úencodingr©rúJ/opt/bitninja-python-dojo/embedded/lib/python3.9/test/test_charmapcodec.pyÚcodec_search_functions  r rc@s,eZdZdd„Zdd„Zdd„Zdd„Zd S) ÚCharmapCodecTestcCs^| tdtƒd¡| tdtƒd¡| tdtƒd¡| tdtƒd¡| td tƒd ¡dS) NóabcÚabcsxdefZabcdefsdefxZdefabcsdxfZdabcfsdxfxZdabcfabc©Ú assertEqualÚstrÚ codecname©ÚselfrrrÚtest_constructorxs z"CharmapCodecTest.test_constructorxcCs^| d t¡d¡| d t¡d¡| d t¡d¡| d t¡d¡| d  t¡d ¡dS) Nr r ZxdefsabcdefZdefxsdefabcZdxfsdabcfZdxfxsdabcfabc)rÚencoderrrrrÚ test_encodex$s zCharmapCodecTest.test_encodexcCsL| tdtƒd¡| tdtƒd¡| tdtƒd¡| tdtƒd¡dS)NsydefÚdefsdefysdyfÚdfsdyfyr rrrrÚtest_constructory+sz"CharmapCodecTest.test_constructorycCs| ttdt¡dS)Nsabc)Z assertRaisesÚ UnicodeErrorrrrrrrÚtest_maptoundefined1sz$CharmapCodecTest.test_maptoundefinedN)Ú__name__Ú __module__Ú __qualname__rrrrrrrrr sr Ú__main__) Ú__doc__ZunittestÚcodecsr ÚregisterrZTestCaser rÚmainrrrrÚs