ó
ŠwÛjc           @   s‚   d  Z  d d l Z d d l Z d d l Z d „  Z e j e ƒ d Z d e j f d „  ƒ  YZ	 d „  Z
 e d k r~ e
 ƒ  n  d S(	   sá    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.

iÿÿÿÿNc         C   s0   |  d k r, d d l  m } t | j ƒ  ƒ Sd  S(   Nt	   testcodeciÿÿÿÿ(   R    (   t   testR    t   tuplet   getregentryt   None(   t   encodingR    (    (    sŒ   /home/sim/yocto/scarthgap/build/tmp/work/x86_64-linux/python-native/2.7.18/recipe-sysroot-native/usr/lib/python2.7/test/test_charmapcodec.pyt   codec_search_function   s    R    t   CharmapCodecTestc           B   s,   e  Z d  „  Z d „  Z d „  Z d „  Z RS(   c         C   s�   |  j  t d t ƒ d ƒ |  j  t d t ƒ d ƒ |  j  t d t ƒ d ƒ |  j  t d t ƒ d ƒ |  j  t d	 t ƒ d
 ƒ d  S(   Nt   abcu   abct   xdefu   abcdeft   defxu   defabct   dxfu   dabcft   dxfxu   dabcfabc(   t   assertEqualt   unicodet	   codecname(   t   self(    (    sŒ   /home/sim/yocto/scarthgap/build/tmp/work/x86_64-linux/python-native/2.7.18/recipe-sysroot-native/usr/lib/python2.7/test/test_charmapcodec.pyt   test_constructorx   s
    c         C   s�   |  j  d j t ƒ d ƒ |  j  d j t ƒ d ƒ |  j  d j t ƒ d ƒ |  j  d j t ƒ d ƒ |  j  d	 j t ƒ d
 ƒ d  S(   Nu   abcR   u   xdeft   abcdefu   defxt   defabcu   dxft   dabcfu   dxfxt   dabcfabc(   R   t   encodeR   (   R   (    (    sŒ   /home/sim/yocto/scarthgap/build/tmp/work/x86_64-linux/python-native/2.7.18/recipe-sysroot-native/usr/lib/python2.7/test/test_charmapcodec.pyt   test_encodex$   s
    c         C   sh   |  j  t d t ƒ d ƒ |  j  t d t ƒ d ƒ |  j  t d t ƒ d ƒ |  j  t d t ƒ d ƒ d  S(   Nt   ydefu   deft   defyt   dyfu   dft   dyfy(   R   R   R   (   R   (    (    sŒ   /home/sim/yocto/scarthgap/build/tmp/work/x86_64-linux/python-native/2.7.18/recipe-sysroot-native/usr/lib/python2.7/test/test_charmapcodec.pyt   test_constructory+   s    c         C   s   |  j  t t d t ƒ d  S(   Ns   abc(   t   assertRaisest   UnicodeErrorR   R   (   R   (    (    sŒ   /home/sim/yocto/scarthgap/build/tmp/work/x86_64-linux/python-native/2.7.18/recipe-sysroot-native/usr/lib/python2.7/test/test_charmapcodec.pyt   test_maptoundefined1   s    (   t   __name__t
   __module__R   R   R   R   (    (    (    sŒ   /home/sim/yocto/scarthgap/build/tmp/work/x86_64-linux/python-native/2.7.18/recipe-sysroot-native/usr/lib/python2.7/test/test_charmapcodec.pyR      s   			c           C   s   t  j j t ƒ d  S(   N(   R   t   test_supportt   run_unittestR   (    (    (    sŒ   /home/sim/yocto/scarthgap/build/tmp/work/x86_64-linux/python-native/2.7.18/recipe-sysroot-native/usr/lib/python2.7/test/test_charmapcodec.pyt	   test_main4   s    t   __main__(   t   __doc__t   test.test_supportR   t   unittestt   codecsR   t   registerR   t   TestCaseR   R$   R    (    (    (    sŒ   /home/sim/yocto/scarthgap/build/tmp/work/x86_64-linux/python-native/2.7.18/recipe-sysroot-native/usr/lib/python2.7/test/test_charmapcodec.pyt   <module>
   s   		