ó
P'—^c           @@  sù   d  d l  m Z d  d l Z d  d l Z d  d l Z d e j f d „  ƒ  YZ d e j f d „  ƒ  YZ d d „ Z
 d „  Z d	 „  Z e d
 k rõ d  d l Z d  d l Z e j j d  e j j e j j e j j e j j e ƒ ƒ ƒ ƒ ƒ e ƒ  n  d S(   i    (   t   absolute_importNt   NoExtensionTestSuitec           B@  s   e  Z d  „  Z RS(   c         C@  s?   d d  l  } | j t ƒ t j j |  | ƒ } | j t ƒ | S(   Ni    (   t
   simplejsont   _toggle_speedupst   Falset   unittestt	   TestSuitet   runt   True(   t   selft   resultR   (    (    s;   /tmp/pip-unpacked-wheel-9xjeDh/simplejson/tests/__init__.pyR      s
    (   t   __name__t
   __module__R   (    (    (    s;   /tmp/pip-unpacked-wheel-9xjeDh/simplejson/tests/__init__.pyR      s   t   TestMissingSpeedupsc           B@  s   e  Z d  „  Z RS(   c         C@  s5   t  t d ƒ r n t  |  d ƒ r1 |  j d ƒ n  d  S(   Nt   pypy_translation_infot   skipTests   _speedups.so is missing!(   t   hasattrt   sysR   (   R	   (    (    s;   /tmp/pip-unpacked-wheel-9xjeDh/simplejson/tests/__init__.pyt   runTest   s    (   R   R   R   (    (    (    s;   /tmp/pip-unpacked-wheel-9xjeDh/simplejson/tests/__init__.pyR      s   c         C@  sÉ   d d  l  } d d  l } d d  l } |  d  k r? t j ƒ  }  n  y d d  l } Wn' t k
 rx t j	 d k  rr |  S‚  n Xx3 | | j
 | j f D] } |  j | j | ƒ ƒ q W|  j | j d ƒ ƒ |  S(   Ni    i   i   s   ../../index.rst(   i   i   (   R   t   simplejson.encodert   simplejson.decodert   NoneR   R   t   doctestt   ImportErrorR   t   version_infot   encodert   decodert   addTestt   DocTestSuitet   DocFileSuite(   t   suiteR   R   t   mod(    (    s;   /tmp/pip-unpacked-wheel-9xjeDh/simplejson/tests/__init__.pyt   additional_tests   s    c          C@  sh   d „  }  |  ƒ  } d d  l  } | j ƒ  d  k rC | j t ƒ  ƒ n! t j | t |  ƒ  g ƒ g ƒ } | S(   Nc          S@  s|   g  t  j t  j j t ƒ ƒ D]A }  |  j d ƒ r |  j d ƒ r d t  j j |  ƒ d f ^ q } t t	 j
 ƒ  j | ƒ ƒ S(   Nt   test_s   .pys   simplejson.tests.%si    (   t   ost   listdirt   patht   dirnamet   __file__t
   startswitht   endswitht   splitextR    R   t
   TestLoadert   loadTestsFromNames(   t   ft   suite_names(    (    s;   /tmp/pip-unpacked-wheel-9xjeDh/simplejson/tests/__init__.pyt	   get_suite,   s
    Ai    (   R   t   _import_c_make_encoderR   R   R   R   R   R   (   R.   R   R   (    (    s;   /tmp/pip-unpacked-wheel-9xjeDh/simplejson/tests/__init__.pyt   all_tests_suite+   s    		c          C@  sK   t  j d d t j j d ƒ ƒ }  t ƒ  } t |  j | ƒ j ƒ  ƒ ‚ d  S(   Nt	   verbosityi   s   -v(	   R   t   TextTestRunnerR   t   argvt   countR0   t
   SystemExitR   t   wasSuccessful(   t   runnerR   (    (    s;   /tmp/pip-unpacked-wheel-9xjeDh/simplejson/tests/__init__.pyt   main@   s    "	t   __main__(   t
   __future__R    R   R   R"   R   R   t   TestCaseR   R   R    R0   R8   R   R$   t   insertR%   t   abspathR&   (    (    (    s;   /tmp/pip-unpacked-wheel-9xjeDh/simplejson/tests/__init__.pyt   <module>   s   			C