-í
•‚É<c      s÷   d  k  l Z d k Z d k Z d k Z d k Z d f  d „  ƒ  YZ d e f d „  ƒ  YZ d e i f d „  ƒ  YZ	 d e	 f d	 „  ƒ  YZ
 d
 e	 f d „  ƒ  YZ d „  Z d „  Z e e ƒ Z e d „ Z d „  Z d „  Z e d j o e ƒ  n d S(   (   s
   generatorsNs   HookWatcherc     s)   d „  Z  d „  Z e d „ Z d „  Z RS(   Nc   s   g  |  _ g  |  _ d  S(   N(   s   selfs   framess   events(   s   self(    (    s6   /usr/local/twc/lib/python2.2/test/test_profilehooks.pys   __init__ s    	c   s   |  i | | ƒ d  S(   N(   s   selfs	   add_events   events   frame(   s   selfs   frames   events   arg(    (    s6   /usr/local/twc/lib/python2.2/test/test_profilehooks.pys   callback s    c   sŽ   | t j o t i d ƒ } n y |  i i | ƒ } Wn2 t j
 o& t	 |  i ƒ } |  i i
 | ƒ n X|  i i
 | | t | ƒ f ƒ d S(   s   Add an event to the log.i   N(   s   frames   Nones   syss	   _getframes   selfs   framess   indexs   framenos
   ValueErrors   lens   appends   eventss   events   ident(   s   selfs   events   frames   frameno(    (    s6   /usr/local/twc/lib/python2.2/test/test_profilehooks.pys	   add_event s     c   sh   t  |  i i ƒ t  t  ƒ g } t |  _ g  i } |  i	 D]% } | d | j o | | ƒ n q8 ~ Sd S(   s   Remove calls to add_event().i   N(   s   idents   selfs	   add_events   im_funcs
   disalloweds   Nones   framess   appends   _[1]s   eventss   item(   s   selfs   _[1]s   items
   disallowed(    (    s6   /usr/local/twc/lib/python2.2/test/test_profilehooks.pys
   get_events s     	  (   s   __init__s   callbacks   Nones	   add_events
   get_events(    (    (    s6   /usr/local/twc/lib/python2.2/test/test_profilehooks.pys   HookWatcher
 s    		s   ProfileSimulatorc     sP   d „  Z  d „  Z d „  Z d „  Z d „  Z h  e d <e d <e d <Z RS(	   Nc   s#   | |  _  g  |  _ t i |  ƒ d  S(   N(   s   testcases   selfs   stacks   HookWatchers   __init__(   s   selfs   testcase(    (    s6   /usr/local/twc/lib/python2.2/test/test_profilehooks.pys   __init__( s    		c   s   |  i | |  | ƒ d  S(   N(   s   selfs   dispatchs   events   frame(   s   selfs   frames   events   arg(    (    s6   /usr/local/twc/lib/python2.2/test/test_profilehooks.pys   callback- s    c   s$   |  i d | ƒ |  i i | ƒ d  S(   Ns   call(   s   selfs	   add_events   frames   stacks   append(   s   selfs   frame(    (    s6   /usr/local/twc/lib/python2.2/test/test_profilehooks.pys
   trace_call1 s    c   s!   |  i d | ƒ |  i i ƒ  d  S(   Ns   return(   s   selfs	   add_events   frames   stacks   pop(   s   selfs   frame(    (    s6   /usr/local/twc/lib/python2.2/test/test_profilehooks.pys   trace_return5 s    c   s   |  i i d ƒ d  S(   Ns2   the profiler should never receive exception events(   s   selfs   testcases   fail(   s   selfs   frame(    (    s6   /usr/local/twc/lib/python2.2/test/test_profilehooks.pys   trace_exception9 s    s   calls	   exceptions   return(   s   __init__s   callbacks
   trace_calls   trace_returns   trace_exceptions   dispatch(    (    (    s6   /usr/local/twc/lib/python2.2/test/test_profilehooks.pys   ProfileSimulator' s    					s   TestCaseBasec     s   d „  Z  RS(   Nc   sS   t  | |  i ƒ  ƒ } | | j o- |  i d t i | ƒ t i | ƒ f ƒ n d  S(   Ns'   Expected events:
%s
Received events:
%s(	   s   capture_eventss   callables   selfs   new_watchers   eventss   expecteds   fails   pprints   pformat(   s   selfs   callables   expecteds   events(    (    s6   /usr/local/twc/lib/python2.2/test/test_profilehooks.pys   check_eventsE s    (   s   check_events(    (    (    s6   /usr/local/twc/lib/python2.2/test/test_profilehooks.pys   TestCaseBaseD s    s   ProfileHookTestCasec     s€   d „  Z  d „  Z d „  Z d „  Z d „  Z d „  Z d „  Z d „  Z d	 „  Z d
 „  Z	 d „  Z
 d „  Z d „  Z d „  Z RS(   Nc   s   t  ƒ  Sd  S(   N(   s   HookWatcher(   s   self(    (    s6   /usr/local/twc/lib/python2.2/test/test_profilehooks.pys   new_watcherM s    c   sA   d „  } t | ƒ } |  i | d d | f d d | f g ƒ d  S(   Nc   s   d  S(   N(    (   s   p(    (    s6   /usr/local/twc/lib/python2.2/test/test_profilehooks.pys   fQ s    i   s   calls   return(   s   fs   idents   f_idents   selfs   check_events(   s   selfs   f_idents   f(    (    s6   /usr/local/twc/lib/python2.2/test/test_profilehooks.pys   test_simpleP s    	c   sA   d „  } t | ƒ } |  i | d d | f d d | f g ƒ d  S(   Nc   s   d d d  S(   Ni   i    (    (   s   p(    (    s6   /usr/local/twc/lib/python2.2/test/test_profilehooks.pys   fY s    i   s   calls   return(   s   fs   idents   f_idents   selfs   check_events(   s   selfs   f_idents   f(    (    s6   /usr/local/twc/lib/python2.2/test/test_profilehooks.pys   test_exceptionX s    	c   sA   d „  } t | ƒ } |  i | d d | f d d | f g ƒ d  S(   Nc   s   y d d Wn n Xd  S(   Ni   i    (    (   s   p(    (    s6   /usr/local/twc/lib/python2.2/test/test_profilehooks.pys   fa s      i   s   calls   return(   s   fs   idents   f_idents   selfs   check_events(   s   selfs   f_idents   f(    (    s6   /usr/local/twc/lib/python2.2/test/test_profilehooks.pys   test_caught_exception` s    	c   sA   d „  } t | ƒ } |  i | d d | f d d | f g ƒ d  S(   Nc   s   y d d Wn n Xd  S(   Ni   i    (    (   s   p(    (    s6   /usr/local/twc/lib/python2.2/test/test_profilehooks.pys   fj s      i   s   calls   return(   s   fs   idents   f_idents   selfs   check_events(   s   selfs   f_idents   f(    (    s6   /usr/local/twc/lib/python2.2/test/test_profilehooks.pys   test_caught_nested_exceptioni s    	c   sA   d „  } t | ƒ } |  i | d d | f d d | f g ƒ d  S(   Nc   s   d d d  S(   Ni   i    (    (   s   p(    (    s6   /usr/local/twc/lib/python2.2/test/test_profilehooks.pys   fs s    i   s   calls   return(   s   fs   idents   f_idents   selfs   check_events(   s   selfs   f_idents   f(    (    s6   /usr/local/twc/lib/python2.2/test/test_profilehooks.pys   test_nested_exceptionr s    	c   s‰   d „  ‰  ‡  d †  } t ˆ  ƒ } t | ƒ } |  i | d d | f d d | f d d | f d d | f d d | f d d | f g ƒ d  S(   Nc   s   d d d  S(   Ni   i    (    (   s   p(    (    s6   /usr/local/twc/lib/python2.2/test/test_profilehooks.pys   f~ s    c   s4   y ˆ  |  ƒ Wn y ˆ  |  ƒ Wn n Xn Xd  S(   N(   s   fs   p(   s   p(   s   f(    s6   /usr/local/twc/lib/python2.2/test/test_profilehooks.pys   g€ s      i   s   calli   s   returni   (   s   fs   gs   idents   f_idents   g_idents   selfs   check_events(   s   selfs   gs   g_idents   fs   f_ident(    (   s   fs6   /usr/local/twc/lib/python2.2/test/test_profilehooks.pys   test_exception_in_except_clause} s
    	c  
 s}   d „  ‰  ‡  d †  } t ˆ  ƒ } t | ƒ } |  i | d d | f d d | f d d | f d d | f d d | f g ƒ d  S(   Nc   s   d d d  S(   Ni   i    (    (   s   p(    (    s6   /usr/local/twc/lib/python2.2/test/test_profilehooks.pys   f‘ s    c   s#   z ˆ  |  ƒ Wd  |  i d ƒ Xd  S(   Ns   falling through(   s   fs   ps	   add_event(   s   p(   s   f(    s6   /usr/local/twc/lib/python2.2/test/test_profilehooks.pys   g“ s     i   s   calli   s   returns   falling through(   s   fs   gs   idents   f_idents   g_idents   selfs   check_events(   s   selfs   gs   g_idents   fs   f_ident(    (   s   fs6   /usr/local/twc/lib/python2.2/test/test_profilehooks.pys   test_exception_propogation s
    	c   sA   d „  } t | ƒ } |  i | d d | f d d | f g ƒ d  S(   Nc   s"   y d d Wn d d n Xd  S(   Ni   i    (    (   s   p(    (    s6   /usr/local/twc/lib/python2.2/test/test_profilehooks.pys   f  s      i   s   calls   return(   s   fs   idents   f_idents   selfs   check_events(   s   selfs   f_idents   f(    (    s6   /usr/local/twc/lib/python2.2/test/test_profilehooks.pys   test_raise_twiceŸ s    	c   sA   d „  } t | ƒ } |  i | d d | f d d | f g ƒ d  S(   Nc   s   y d d Wn
 ‚  n Xd  S(   Ni   i    (    (   s   p(    (    s6   /usr/local/twc/lib/python2.2/test/test_profilehooks.pys   f© s      i   s   calls   return(   s   fs   idents   f_idents   selfs   check_events(   s   selfs   f_idents   f(    (    s6   /usr/local/twc/lib/python2.2/test/test_profilehooks.pys   test_raise_reraise¨ s    	c   sA   d „  } t | ƒ } |  i | d d | f d d | f g ƒ d  S(   Nc   s   t  ƒ  ‚ d  S(   N(   s	   Exception(   s   p(    (    s6   /usr/local/twc/lib/python2.2/test/test_profilehooks.pys   f² s    i   s   calls   return(   s   fs   idents   f_idents   selfs   check_events(   s   selfs   f_idents   f(    (    s6   /usr/local/twc/lib/python2.2/test/test_profilehooks.pys
   test_raise± s    	c   s  d „  ‰ ‡ d †  ‰  ‡  d †  ‰ ‡ d †  ‰ ‡ d †  } t ˆ ƒ }	 t ˆ  ƒ } t ˆ ƒ } t ˆ ƒ } t | ƒ }
 |  i | d d |
 f d d | f d	 d | f d
 d | f d d |	 f d d |	 f d
 d | f d	 d | f d d | f d d |
 f g
 ƒ d  S(   Nc     s   d d d  S(   Ni   i    (    (    (    (    s6   /usr/local/twc/lib/python2.2/test/test_profilehooks.pys   fº s    c     s   ˆ  ƒ  d  S(   N(   s   f(    (   s   f(    s6   /usr/local/twc/lib/python2.2/test/test_profilehooks.pys   g¼ s    c     s   ˆ  ƒ  d  S(   N(   s   g(    (   s   g(    s6   /usr/local/twc/lib/python2.2/test/test_profilehooks.pys   h¾ s    c     s   ˆ  ƒ  d  S(   N(   s   h(    (   s   h(    s6   /usr/local/twc/lib/python2.2/test/test_profilehooks.pys   iÀ s    c   s   ˆ  ƒ  d  S(   N(   s   i(   s   p(   s   i(    s6   /usr/local/twc/lib/python2.2/test/test_profilehooks.pys   jÂ s    i   s   calli   i   i   i   s   return(   s   fs   gs   hs   is   js   idents   f_idents   g_idents   h_idents   i_idents   j_idents   selfs   check_events(   s   selfs   h_idents   gs   g_idents   is   hs   fs   js   i_idents   f_idents   j_ident(    (   s   gs   is   hs   fs6   /usr/local/twc/lib/python2.2/test/test_profilehooks.pys   test_distant_exception¹ s    	c   s¡   d „  ‰  ‡  d †  } t ˆ  ƒ } t | ƒ } |  i | d d | f d d | f d d | f d d | f d d | f d d | f d d | f d d | f g ƒ d  S(   Nc    #s   x t  d ƒ D]
 }  |  Vq Wd  S(   Ni   (   s   ranges   i(   s   i(    (    s6   /usr/local/twc/lib/python2.2/test/test_profilehooks.pys   fÖ s     c   s   x ˆ  ƒ  D] } q
 Wd  S(   N(   s   fs   i(   s   ps   i(   s   f(    s6   /usr/local/twc/lib/python2.2/test/test_profilehooks.pys   gÙ s    
 i   s   calli   s   return(   s   fs   gs   idents   f_idents   g_idents   selfs   check_events(   s   selfs   gs   g_idents   fs   f_ident(    (   s   fs6   /usr/local/twc/lib/python2.2/test/test_profilehooks.pys   test_generatorÕ s
    	c   s¡   d „  ‰  ‡  d †  } t ˆ  ƒ } t | ƒ } |  i | d d | f d d | f d d | f d d | f d d | f d d | f d d | f d d | f g ƒ d  S(   Nc    #s%   x t  d ƒ D]
 }  |  Vq Wt ‚ d  S(   Ni   (   s   ranges   is   StopIteration(   s   i(    (    s6   /usr/local/twc/lib/python2.2/test/test_profilehooks.pys   fì s     c   s   x ˆ  ƒ  D] } q
 Wd  S(   N(   s   fs   i(   s   ps   i(   s   f(    s6   /usr/local/twc/lib/python2.2/test/test_profilehooks.pys   gð s    
 i   s   calli   s   return(   s   fs   gs   idents   f_idents   g_idents   selfs   check_events(   s   selfs   gs   g_idents   fs   f_ident(    (   s   fs6   /usr/local/twc/lib/python2.2/test/test_profilehooks.pys   test_stop_iterationë s
    	(   s   new_watchers   test_simples   test_exceptions   test_caught_exceptions   test_caught_nested_exceptions   test_nested_exceptions   test_exception_in_except_clauses   test_exception_propogations   test_raise_twices   test_raise_reraises
   test_raises   test_distant_exceptions   test_generators   test_stop_iteration(    (    (    s6   /usr/local/twc/lib/python2.2/test/test_profilehooks.pys   ProfileHookTestCaseL s    																	s   ProfileSimulatorTestCasec     s/   d „  Z  d „  Z d „  Z d „  Z d „  Z RS(   Nc   s   t  |  ƒ Sd  S(   N(   s   ProfileSimulators   self(   s   self(    (    s6   /usr/local/twc/lib/python2.2/test/test_profilehooks.pys   new_watchers    c   sA   d „  } t | ƒ } |  i | d d | f d d | f g ƒ d  S(   Nc   s   d  S(   N(    (   s   p(    (    s6   /usr/local/twc/lib/python2.2/test/test_profilehooks.pys   fs    i   s   calls   return(   s   fs   idents   f_idents   selfs   check_events(   s   selfs   f_idents   f(    (    s6   /usr/local/twc/lib/python2.2/test/test_profilehooks.pys   test_simples    	c   sA   d „  } t | ƒ } |  i | d d | f d d | f g ƒ d  S(   Nc   s   d d d  S(   Ni   i    (    (   s   p(    (    s6   /usr/local/twc/lib/python2.2/test/test_profilehooks.pys   fs    i   s   calls   return(   s   fs   idents   f_idents   selfs   check_events(   s   selfs   f_idents   f(    (    s6   /usr/local/twc/lib/python2.2/test/test_profilehooks.pys   test_basic_exceptions    	c   sA   d „  } t | ƒ } |  i | d d | f d d | f g ƒ d  S(   Nc   s   y d d Wn n Xd  S(   Ni   i    (    (   s   p(    (    s6   /usr/local/twc/lib/python2.2/test/test_profilehooks.pys   fs      i   s   calls   return(   s   fs   idents   f_idents   selfs   check_events(   s   selfs   f_idents   f(    (    s6   /usr/local/twc/lib/python2.2/test/test_profilehooks.pys   test_caught_exceptions    	c   s  d „  ‰ ‡ d †  ‰  ‡  d †  ‰ ‡ d †  ‰ ‡ d †  } t ˆ ƒ }	 t ˆ  ƒ } t ˆ ƒ } t ˆ ƒ } t | ƒ }
 |  i | d d |
 f d d | f d	 d | f d
 d | f d d |	 f d d |	 f d
 d | f d	 d | f d d | f d d |
 f g
 ƒ d  S(   Nc     s   d d d  S(   Ni   i    (    (    (    (    s6   /usr/local/twc/lib/python2.2/test/test_profilehooks.pys   f s    c     s   ˆ  ƒ  d  S(   N(   s   f(    (   s   f(    s6   /usr/local/twc/lib/python2.2/test/test_profilehooks.pys   g"s    c     s   ˆ  ƒ  d  S(   N(   s   g(    (   s   g(    s6   /usr/local/twc/lib/python2.2/test/test_profilehooks.pys   h$s    c     s   ˆ  ƒ  d  S(   N(   s   h(    (   s   h(    s6   /usr/local/twc/lib/python2.2/test/test_profilehooks.pys   i&s    c   s   ˆ  ƒ  d  S(   N(   s   i(   s   p(   s   i(    s6   /usr/local/twc/lib/python2.2/test/test_profilehooks.pys   j(s    i   s   calli   i   i   i   s   return(   s   fs   gs   hs   is   js   idents   f_idents   g_idents   h_idents   i_idents   j_idents   selfs   check_events(   s   selfs   h_idents   gs   g_idents   is   hs   fs   js   i_idents   f_idents   j_ident(    (   s   gs   is   hs   fs6   /usr/local/twc/lib/python2.2/test/test_profilehooks.pys   test_distant_exceptions    	(   s   new_watchers   test_simples   test_basic_exceptions   test_caught_exceptions   test_distant_exception(    (    (    s6   /usr/local/twc/lib/python2.2/test/test_profilehooks.pys   ProfileSimulatorTestCases
    					c   s:   t  |  d ƒ o |  i } n
 |  i } | i | i f Sd  S(   Ns   f_code(   s   hasattrs   functions   f_codes   codes	   func_codes   co_firstlinenos   co_name(   s   functions   code(    (    s6   /usr/local/twc/lib/python2.2/test/test_profilehooks.pys   ident<s    	c   s   y |  | ƒ Wn n Xd  S(   N(   s   fs   p(   s   fs   p(    (    s6   /usr/local/twc/lib/python2.2/test/test_profilehooks.pys   protectDs      c   sY   | t j o t ƒ  } n t i | i ƒ t |  | ƒ t i t ƒ | i ƒ  d d !Sd  S(   Ni   iÿÿÿÿ(	   s   ps   Nones   HookWatchers   syss
   setprofiles   callbacks   protects   callables
   get_events(   s   callables   p(    (    s6   /usr/local/twc/lib/python2.2/test/test_profilehooks.pys   capture_eventsKs    c   s    d  k  } | i  t |  ƒ ƒ d  S(   N(   s   pprints   capture_eventss   callable(   s   callables   pprint(    (    s6   /usr/local/twc/lib/python2.2/test/test_profilehooks.pys   show_eventsTs    	c    sU   t  i ƒ  } t  i ƒ  }  |  i | i t ƒ ƒ |  i | i t ƒ ƒ t	 i
 |  ƒ d  S(   N(   s   unittests
   TestLoaders   loaders	   TestSuites   suites   addTests   loadTestsFromTestCases   ProfileHookTestCases   ProfileSimulatorTestCases   test_supports	   run_suite(   s   suites   loader(    (    s6   /usr/local/twc/lib/python2.2/test/test_profilehooks.pys	   test_mainYs
    s   __main__(   s
   __future__s
   generatorss   pprints   syss   unittests   test_supports   HookWatchers   ProfileSimulators   TestCases   TestCaseBases   ProfileHookTestCases   ProfileSimulatorTestCases   idents   protects   protect_idents   Nones   capture_eventss   show_eventss	   test_mains   __name__(   s   test_supports   HookWatchers   protects   idents   show_eventss   ProfileHookTestCases   capture_eventss   unittests   pprints   syss   TestCaseBases
   generatorss	   test_mains   ProfileSimulatorTestCases   protect_idents   ProfileSimulator(    (    s6   /usr/local/twc/lib/python2.2/test/test_profilehooks.pys   ? s"   				¶:					