mς
­fIc           @   so   d  k  Z  d  k Z d  k Z d  k Z d k l Z d e i f d     YZ d   Z e d j o e   n d  S(   N(   s   test_supportt   TestCasec           B   sb   t  Z d   Z d   Z d   Z d   Z d   Z d   Z d   Z d   Z	 d	   Z
 d
   Z RS(   Nc         C   s΄   t  i    } | t _ t _ t i } g  t _ zG t i |  i
  t i |  i  t i |  i d d d t i   Wd  t i t _ t i t _ | t _ X|  i | i   d  d  S(   Ni   t   kwt   abcs"   h4 (4,) {'kw': 'abc'}
h4 () {}
h1
(   t   StringIOt   st   syst   stdoutt   stderrt   atexitt   _exithandlerst   save_handlerst   registert   selft   h1t   h4t   _run_exitfuncst
   __stdout__t
   __stderr__t   assertEqualt   getvalue(   R   R
   R   (    (    t-   /mit/python/lib/python2.4/test/test_atexit.pyt	   test_args   s    		 
c         C   s«   t  i    } | t _ t _ t i } g  t _ z> t i |  i
  t i |  i  t i |  i  t i   Wd  t i t _ t i t _ | t _ X|  i | i   d  d  S(   Ns	   h3
h2
h1
(   R   R   R   R   R   R   R	   R
   R   R   R   t   h2t   h3R   R   R   R   R   (   R   R
   R   (    (    R   t
   test_order   s    		 
c         C   s³   t  i    } | t _ t _ t i } g  t _ t i } |  i t _ t t  z t i |  i  t i   Wd  t i t _ t i t _ | t _ | t _ X|  i | i   d  d  S(   Ns   h2
h1
(   R   R   R   R   R   R   R	   R
   t   exitfunct   exfuncR   R   t   reloadR   R   R   R   R   R   R   (   R   R
   R   R   (    (    R   t   test_sys_override*   s     			
 	
c         C   s   t  i    } | t _ t _ t i } g  t _ z7 t i |  i
  t i |  i  |  i t t i  Wd  t i t _ t i t _ | t _ Xd  S(   N(   R   R   R   R   R   R   R	   R
   R   R   t   raise1t   raise2t   assertRaisest	   TypeErrorR   R   R   (   R   R
   R   (    (    R   t
   test_raise=   s    		 c         C   s	   d GHd  S(   NR   (    (   R   (    (    R   R   M   s    c         C   s	   d GHd  S(   NR   (    (   R   (    (    R   R   P   s    c         C   s	   d GHd  S(   NR   (    (   R   (    (    R   R   S   s    c         O   s   d G| G| GHd  S(   NR   (   t   argst   kwargs(   R   R"   R#   (    (    R   R   V   s    c         C   s
   t   d  S(   N(   R    (   R   (    (    R   R   Y   s    c         C   s
   t   d  S(   N(   t   SystemError(   R   (    (    R   R   \   s    (   t   __name__t
   __module__R   R   R   R!   R   R   R   R   R   R   (    (    (    R   R       s   									c           C   s   t  i t  d  S(   N(   t   test_supportt   run_unittestR    (    (    (    R   t	   test_main_   s    t   __main__(	   R   t   unittestR   R   t   testR'   R    R)   R%   (   R'   R    R   R+   R   R   R)   (    (    R   t   ?   s   				X	