+
    Bis                        ^ RI t ^ RIt^ RIt^ RIt^ RIt^ RIt^ RIt^ RI	t	^ RI
t
^ RIt^ RIHt ^ RIHt  ^ RIHt R t ! R R]
P(                  4      t ! R R	4      t ! R
 R]4      t ! R R4      t ! R R]4      t ! R R]4      t]
P:                  ! ]RJ R4       ! R R]
P(                  4      4       t]R8X  d   ]
P@                  ! 4        R# R#   ] d    Rt Li ; i)    N)support)threading_helperhamtc                F   a  \         P                  ! S 4      V 3R l4       pV# )z*Needed to make reftracking test mode work.c                  Z   < \         P                  ! 4       pVP                  ! S.V O5/ VB # NcontextvarsContextrun)argskwargsctxfuncs   *, (/usr/lib/python3.14/test/test_context.pywrapper!isolated_context.<locals>.wrapper   s*    !!#wwt-d-f--    )	functoolswraps)r   r   s   f r   isolated_contextr      s%    __T. . Nr   c                     a  ] tR t^t o R t]R 4       t]R 4       tR tR t	R t
R tR tR	 tR
 tR t]R 4       tR tR tR t]R 4       t]R 4       t]R 4       t]R 4       t]R 4       tR tR t]]P8                  ! 4       R 4       4       t]]P8                  ! 4       R 4       4       tR tR t R t!R t"R t#R t$R t%R t&V t'R!# )"ContextTestc                p   V P                  \        R 4      ;_uu_ 4        \        P                  ! 4        RRR4       V P                  \        R4      ;_uu_ 4        \        P                  ! ^4       RRR4       \        P                  ! R4      pV P	                  VP
                  R4       V P                  \        4      ;_uu_ 4        RVn        RRR4       V P                  \        V4      \        R4      4       R#   + '       g   i     L; i  + '       g   i     L; i  + '       g   i     L\; i)ztakes exactly 1Nzmust be a straaabbb)
assertRaisesRegex	TypeErrorr   
ContextVarassertEqualnameassertRaisesAttributeErrorassertNotEqualhash)selfcs   & r   test_context_var_new_1"ContextTest.test_context_var_new_1   s    ##I/@AA""$ B ##I??""1% @ ""5)'~..AF / 	DGT%[1 BA @? /.s#   C?D	D%?D	D"	%D5	c                   \         P                  ! R 4      pV P                  R \        V4      4       \         P                  ! R ^{R7      pV P                  R\        V4      4       . p\         P                  ! R VR7      pVP	                  V4       V P                  R\        V4      4       V P                  R\        V4      4       VP                  ^4      pV P                  \        V4      \        V4      4       V P                  R\        V4      4       VP                  V4       V P                  R\        V4      4       R# )adefault123z...z used N)r   r    assertInreprappendsetassertNotInreset)r'   r(   lstts   &   r   test_context_var_repr_1#ContextTest.test_context_var_repr_1-   s    ""3'c47#""34eT!W%""34

1eT!W%eT#Y'EE!Hd1gtAw'47+	
hQ(r   c                    \         P                  ! R 4      pVP                  ^4      pV P                  \	        V4      R4       R# )r,   zG^<Token var=<ContextVar name='a' at 0x[0-9a-fA-F]+> at 0x[0-9a-fA-F]+>$N)r   r    r3   assertRegexr1   )r'   r(   toks   &  r   test_token_repr_1ContextTest.test_token_repr_1A   s:    ""3'eeAhcC	Dr   c                   V P                  \        R 4      ;_uu_ 4         ! R R\        P                  4      pRRR4       V P                  \        R 4      ;_uu_ 4         ! R R\        P                  4      pRRR4       V P                  \        R 4      ;_uu_ 4         ! R R\        P
                  4      pRRR4       R#   + '       g   i     L; i  + '       g   i     Le; i  + '       g   i     R# ; i)znot an acceptable base typec                       ] tR t^KtRtR# )<ContextTest.test_context_subclassing_1.<locals>.MyContextVar N__name__
__module____qualname____firstlineno____static_attributes__rB   r   r   MyContextVarrA   K   s    r   rI   Nc                       ] tR t^PtRtR# )9ContextTest.test_context_subclassing_1.<locals>.MyContextrB   NrC   rB   r   r   	MyContextrK   P       r   rL   c                       ] tR t^TtRtR# )7ContextTest.test_context_subclassing_1.<locals>.MyTokenrB   NrC   rB   r   r   MyTokenrO   T   rM   r   rP   )r   r   r   r    r   Token)r'   rI   rL   rP   s   &   r   test_context_subclassing_1&ContextTest.test_context_subclassing_1I   s    ##I/LMM{55  N
 ##I/LMMK//  N ##I/LMM+++  NM NM
 NM NMMs#   CCC)C	C&	)C:	c                   V P                  \        R 4      ;_uu_ 4        \        P                  ! ^4       RRR4       V P                  \        R 4      ;_uu_ 4        \        P                  ! ^^R7       RRR4       V P                  \        R 4      ;_uu_ 4        \        P                  ! ^R7       RRR4       \        P                  ! R/ / B  R#   + '       g   i     L; i  + '       g   i     Ly; i  + '       g   i     LN; i)zany argumentsNr,   rB   )r   r   r   r   r'   s   &r   test_context_new_1ContextTest.test_context_new_1W   s    ##I??" @##I??Q' @##I??!$ @!b! @?????s#   CC&C9C#	&C6	9D		c                     ! R  R\         4      pV P                  \        R4      ;_uu_ 4        \        P                  ! V! 4       4       RRR4       R#   + '       g   i     R# ; i)c                   &   a  ] tR t^bt o R tRtV tR# )GContextTest.test_context_new_unhashable_str_subclass.<locals>.weird_strc                    R # r	   rB   r'   others   &&r   __eq__NContextTest.test_context_new_unhashable_str_subclass.<locals>.weird_str.__eq__c   s    r   rB   N)rD   rE   rF   rG   r_   rH   __classdictcell____classdict__s   @r   	weird_strr[   b   s      r   rd   zunhashable typeN)strr   r   r   r    )r'   rd   s   & r   (test_context_new_unhashable_str_subclass4ContextTest.test_context_new_unhashable_str_subclass`   sD    	 	 ##I/@AA""9;/ BAAAs   AA%	c                   \         P                  ! 4       pV P                  \        R 4      ;_uu_ 4        V^,           RRR4       V P                  \        R 4      ;_uu_ 4        ^V9    RRR4       V P                  \        R 4      ;_uu_ 4        VP	                  ^4       RRR4       R#   + '       g   i     Lv; i  + '       g   i     L]; i  + '       g   i     R# ; i)zContextVar key was expectedN)r   r   r   r   getr'   r   s   & r   test_context_typerrors_1$ContextTest.test_context_typerrors_1i   s    !!###I/LMMF N##I/LMMH N##I/LMMGGAJ NM	 NMMMMMMs#   
B,$B?C,B<	?C	C#	c                p    \         P                  ! 4       pV P                  V\         P                  4       R # r	   )r   copy_contextassertIsInstancer   rj   s   & r   test_context_get_context_1&ContextTest.test_context_get_context_1s   s&    &&(c;#6#67r   c                    \         P                  ! 4       pV P                  \        R 4      ;_uu_ 4        VP	                  4        RRR4       R#   + '       g   i     R# ; i)zmissing 1 requiredN)r   r   r   r   r   rj   s   & r   test_context_run_1ContextTest.test_context_run_1w   s=    !!###I/CDDGGI EDDDs   AA 	c           	     (   \         P                  ! 4       pR  pV\        P                  ! V4      3 F  pV P	                  VP                  V4      RRR/34       V P	                  VP                  V^4      RRR/34       V P	                  VP                  V^R7      RR^RR/34       V P	                  VP                  V^^R7      RR^RR/34       / pV P	                  VP
                  ! V^3/ VB RRR/34       V P	                  V/ 4       K  	  R# )	c                  $    R VR&   V R,          p W3# )foospambarrB   r   r   s   *,r   r   ,ContextTest.test_context_run_2.<locals>.func   s    "F6NHD<r   rx   rw   rU   r,   Nry   )   rz   )   rz   )r   r   r   partialr!   r   )r'   r   r   fr,   s   &    r   test_context_run_2ContextTest.test_context_run_2}   s   !!#	 
 	))$/0A SWWQZ(VUO)DESWWQ]Z&%,IJQCFE235 2#sAvu568 A2##vuo.0 Q#% 1r   c           	         \         P                  ! 4       pR  pV P                  \        4      ;_uu_ 4        VP	                  V4       RRR4       V P                  \        4      ;_uu_ 4        VP	                  V^^4       RRR4       V P                  \        4      ;_uu_ 4        VP	                  V^^^{R7       RRR4       R#   + '       g   i     L; i  + '       g   i     L`; i  + '       g   i     R# ; i)c                      ^^ ,           R# r}   NrB   r{   s   *,r   r   ,ContextTest.test_context_run_3.<locals>.func   s    EEr   NrU   )r   r   r#   ZeroDivisionErrorr   )r'   r   r   s   &  r   test_context_run_3ContextTest.test_context_run_3   s    !!#	 011GGDM 2011GGD!Q 2011GGD!Q#G& 21	 2111111s#   C-C&C,C	C)	,C=	c                H  a aaa \         P                  ! 4       p\         P                  ! 4       o\         P                  ! R 4      oV V3R loVVV V3R lpVP                  V4      pS P	                  W4       S P	                  VS,          R4       S P                  SV4       R# )varc                  H   < S P                  SP                  R 4      4       R # r	   )assertIsNoneri   r'   r   s   r   func2-ContextTest.test_context_run_4.<locals>.func2   s    cggdm,r   c                  `  < SP                  SP                  R 4      4       SP                  R4       SP                  S4       SP	                  SP                  R 4      R4       \
        P                  ! 4       p SP	                  \        V 4      ^4       SP	                  V S,          R4       V # Nrx   )r   ri   r3   r   r!   r   rn   len)curctx2r   r'   r   s    r   func1-ContextTest.test_context_run_4.<locals>.func1   s    cggdm,GGFOHHUOSWWT]F3**,CSXq)SXv.Jr   rx   N)r   r   r    r   r!   r0   )r'   ctx1r   returned_ctxr   r   r   s   f   @@@r   test_context_run_4ContextTest.test_context_run_4   s~    ""$""$$$U+	-		 		 xx,c*F3c<(r   c                B  a a \         P                  ! 4       p\         P                  ! R 4      oV V3R lpS P                  \        4      ;_uu_ 4        VP                  V4       RRR4       S P                  SP                  R4      4       R#   + '       g   i     L2; i)r   c                  |   < S P                  SP                  R 4      4       SP                  R4       ^^ ,           R # r   )r   ri   r3   r   s   r   r   ,ContextTest.test_context_run_5.<locals>.func   s-    cggdm,GGFOEEr   N)r   r   r    r#   r   r   r   ri   )r'   r   r   r   s   f  @r   test_context_run_5ContextTest.test_context_run_5   sk    !!#$$U+	
 011GGDM 2 	#''$-( 21s   BB	c                   a aa \         P                  ! 4       o\         P                  ! R ^ R7      oVVV 3R lpSP                  V4       R# )r,   r-   c                  ,  < SP                  S P                  4       ^ 4       SP                  SP                  S 4      4       S P                  ^*4       SP                  S P                  4       ^*4       SP                  SP                  S 4      ^*4       R# r   N)r!   ri   r   r3   )r(   r   r'   s   r   fun+ContextTest.test_context_run_6.<locals>.fun   sh    QUUWa(cggaj)EE"IQUUWb)SWWQZ,r   Nr   r   r    r   r'   r   r(   r   s   f @@r   test_context_run_6ContextTest.test_context_run_6   s5    !!#""32	- 	r   c                h   a aa \         P                  ! 4       oVVV 3R  loSP                  S4       R# )c                     < SP                  \        R 4      ;_uu_ 4        S P                  S4       RRR4       R#   + '       g   i     R# ; i)zis already enteredN)r   RuntimeErrorr   )r   r   r'   s   r   r   +ContextTest.test_context_run_7.<locals>.fun   s2    ''6JKK LKKKs	   <A	Nr
   )r'   r   r   s   f@@r   test_context_run_7ContextTest.test_context_run_7   s#    !!#	 	r   c                	   \         P                  ! R 4      pV P                  \        4      ;_uu_ 4        VP	                  4        RRR4       V P                  VP	                  R4      4       VP                  ^*4      pV P                  VP	                  4       ^*4       V P                  VP	                  R4      ^*4       V P                  VP                  VP                  4       V P                  VP                  \         P                  P                  4       V P                  VP                  V4       VP                  R4      pV P                  VP	                  4       R4       V P                  VP	                  R4      R4       V P                  VP                  ^*4       VP                  V4       V P                  VP	                  4       ^*4       V P                  VP	                  R4      ^*4       VP                  R4       V P                  \        R4      ;_uu_ 4        VP                  V4       RRR4       V P                  VP	                  4       R4       \         P                   ! 4       pV P#                  W4       VP                  V4       V P                  \        R4      ;_uu_ 4        VP                  V4       RRR4       V P                  VP	                  R4      4       V P#                  W4       V P                  WA,          R4       V P                  VP	                  VR4      R4       V P                  \%        V4      ^4       V P                  \'        VP)                  4       4      VR3.4       V P                  \'        VP+                  4       4      R.4       V P                  \'        VP-                  4       4      V.4       V P                  \'        V4      V.4       \         P                   ! 4       pV P/                  W4       V P                  \0        4      ;_uu_ 4        WQ,           RRR4       V P                  VP	                  VR4      R4       V P                  \%        V4      ^ 4       V P                  \'        V4      . 4       R#   + '       g   i     ELa; i  + '       g   i     EL; i  + '       g   i     EL	; i  + '       g   i     L; i)r(   Nrx   spam2zhas already been usedaa)r   r    r#   LookupErrorri   r   r3   r!   assertIs	old_valueMISSINGrQ   r   r5   r   r   rn   r0   r   listitemsvalueskeysr4   KeyError)r'   r(   t0r7   r   r   s   &     r   test_context_getset_1!ContextTest.test_context_getset_1   s`   ""3'{++EEG , 	!%%+&UU2Y"%tb)bllBJJ/bllK$5$5$=$=>bffa EE&M&)tf-b)	
"%tb)	g##L2IJJGGAJ K'*'')a	##L2IJJGGBK K!%%+&a'*!T*G4TA&djjl+q'l^<dkkm,wi8diik*QC0daS)'')!x((G )!T*D1TA&dR(c ,++, KJJ KJJ )(s/   R$R13S2	SR.	1S	S	S)	c                   \         P                  ! R 4      p\         P                  ! R4      pVP                  ^*4      pV P                  \        R4      ;_uu_ 4        VP                  V4       RRR4       R#   + '       g   i     R# ; i)v1v2zby a differentN)r   r    r3   r   
ValueErrorr5   )r'   r   r   t1s   &   r   test_context_getset_2!ContextTest.test_context_getset_2  s^    ##D)##D)VVBZ##J0@AAHHRL BAAAs   A88B		c                   a aa \         P                  ! R ^*R7      o\         P                  ! 4       oVVV 3R lpSP                  V4       R# )r(   r-   c                  j  < SP                  SP                  4       ^*4       SP                  \        4      ;_uu_ 4        SS,           RRR4       SP	                  SP                  S4      4       SP                  SP                  SR4      R4       SP                  SS4       SP                  \        SP                  4       4      . 4       SP                  ^4      p SP                  \        SP                  4       4      S.4       SP                  SS,          ^4       SP                  V 4       SP                  \        SP                  4       4      . 4       SP                  \        4      ;_uu_ 4        SS,           RRR4       R#   + '       g   i     ELM; i  + '       g   i     R# ; i)*   Nrx   )
r!   ri   r#   r   r   r4   r   r   r3   r5   )r7   r(   r   r'   s    r   r   .ContextTest.test_context_getset_3.<locals>.fun(  s.   QUUWb)""8,,A -cggaj)SWWQ/8Q$T#((*-r2aAT#((*-s3SVQ'GGAJT#((*-r2""8,,A -, -,, -,,s   
F9
F!F	!F2	N)r   r    r   r   r   s   f @@r   test_context_getset_3!ContextTest.test_context_getset_3#  s5    ""33!!#	$ 	r   c                0   \         P                  ! R ^*R7      p\         P                  ! 4       pVP                  VP                  ^4      pV P                  \        R4      ;_uu_ 4        VP                  V4       RRR4       R#   + '       g   i     R# ; i)r(   r-   zdifferent ContextN)r   r    r   r   r3   r   r   r5   )r'   r(   r   r<   s   &   r   test_context_getset_4!ContextTest.test_context_getset_4<  se    ""33!!#ggaeeQ##J0CDDGGCL EDDDs   (BB	c                   a a \         P                  ! R ^*R7      oSP                  . 4       VV 3R lp\         P                  ! 4       P	                  V4       S P                  SP                  4       . 4       R# )r(   r-   c                     < S P                  . 4       S P                  4       P                  ^*4       SP                  S P                  4       ^*.4       R# )r   N)r3   ri   r2   r!   r(   r'   s   r   r   .ContextTest.test_context_getset_5.<locals>.funK  s8    EE"IEEGNN2QUUWrd+r   N)r   r    r3   rn   r   r!   ri   )r'   r   r(   s   f @r   test_context_getset_5!ContextTest.test_context_getset_5F  sT    ""33	b		,
 	  "&&s+"%r   c                   a aaa \         P                  ! 4       o\         P                  ! R ^*R7      oVVVV 3R lpVV 3R loSP                  V4       R# )r(   r-   c                    < SP                  ^
4       SP                  4       p SP                  V S,          ^
4       SP                  ^4       SP                  SS,          ^4       SP                  V S,          ^
4       V P                  S4       SP                  SS,          ^4       SP                  V S,          ^4       R# 
   N)r3   copyr!   r   )r   r(   r   ctx2_funr'   s    r   ctx1_fun1ContextTest.test_context_copy_1.<locals>.ctx1_funW  s    EE"I99;DT!Wb)EE"IT!Wb)T!Wb)HHXT!Wb)T!Wb)r   c                     < SP                  S P                  4       ^
4       S P                  ^4       SP                  S P                  4       ^4       R# r   )r!   ri   r3   r   s   r   r   1ContextTest.test_context_copy_1.<locals>.ctx2_fune  s:    QUUWb)EE"IQUUWb)r   Nr   )r'   r   r(   r   r   s   f @@@r   test_context_copy_1ContextTest.test_context_copy_1S  s@    ""$""33	* 	*	*
 	r   c                   \         P                  ! 4       pV P                  V\        P                  P
                  4       V P                  \        \         P                  \        P                  P
                  4      4       RpV FI  pV P                  VR7      ;_uu_ 4        V P                  \        \        W4      4      4       RRR4       KK  	  R#   + '       g   i     K`  ; i)__contains__)r"   N)
r   r_   __getitem____iter____len____ne__ri   r   r   r   )r   r   ro   collectionsabcMapping
assertTrue
issubclasssubTestcallablegetattr)r'   r   mapping_methodsr"   s   &   r   test_context_isinstance#ContextTest.test_context_isinstancel  s    !!#c;??#:#:;
;#6#68O8OPQ
 $D4((); <= )( $(((s   "$CC%c                `  a a \         P                  ! R 4      oVV 3R lp\        P                  P	                  ^
R7      p \        VP                  V\        ^
4      4      4      pVP                  4        S P                  V\        \        ^
4      4      4       R#   TP                  4        i ; i)cvarc                    < \        ^
4       Fk  pSP                  W,           4       \        P                  ! \        P
                  ! RR4      4       SP                  SP                  4       W,           4       Km  	  V # )r   gMbP?g?)ranger3   timesleeprandomuniformr!   ri   )numir   r'   s   & r   sub/ContextTest.test_context_threads_1.<locals>.sub~  sU    2Y!

6>>%67  SW5  Jr   )max_workersN)
r   r    
concurrentfuturesThreadPoolExecutorr   mapr   shutdownr!   )r'   r   tpresultsr   s   f   @r   test_context_threads_1"ContextTest.test_context_threads_1y  s     %%f-	 22r2B	266#uRy12GKKM$uRy/2 KKMs   $B B-c                  a aa	 ^ RI p\        P                  ! R4      o	V	V 3R lpS	P                  ^4       VP	                  VR7      pVP                  4        VP                  4        VP	                  VRR7      pVP                  4        VP                  4        \        P                  ! 4       pRoV3R lpVP                  V4       VV 3R lpVP	                  WdR7      pVP                  4        VP                  4        V	V 3R lpVP	                  V\        P                  ! 4       R7      pVP                  4        VP                  4        R# )	r   Nr   c                     < \         P                  P                  '       d   ^p MRp SP                  SP	                  R4      V 4       R# r   )sysflagsthread_inherit_contextr!   ri   )expectedr   r'   s    r   run_context_noneAContextTest.test_context_thread_inherit.<locals>.run_context_none  s5    yy///TXXd^X6r   )target)r  contextc                  V   < \         P                  ! R 4      o S P                  ^4       R# )customN)r   r    r3   )
custom_vars   r   setup_context>ContextTest.test_context_thread_inherit.<locals>.setup_context  s    $//9JNN1r   c                  H   < SP                  S P                  4       ^4       R# )   N)r!   ri   )r  r'   s   r   
run_custom;ContextTest.test_context_thread_inherit.<locals>.run_custom  s    Z^^-q1r   c                     < SP                  \        4      ;_uu_ 4        S P                  4        R R R 4       R #   + '       g   i     R # ; ir	   )r#   r   ri   )r   r'   s   r   	run_empty:ContextTest.test_context_thread_inherit.<locals>.run_empty  s,    "";//
 0///s	   :A	)		threadingr   r    r3   Threadstartjoinr   r   )
r'   r  r  thread
custom_ctxr  r  r  r  r   s
   f       @@r   test_context_thread_inherit'ContextTest.test_context_thread_inherit  s    	%%f-	7 	!!)9!: !!)94!H !((*

	
 	}%	2 !!!H	 !!K<O<O<Q!Rr   c                   a a \         P                  ! 4       p\         P                  ! R ^*R7      oVV 3R lpVP                  V4       R# )r(   r-   c                     < S P                  ^$4      ;_uu_ 4        SP                  S P                  4       ^$4       RRR4       SP                  S P                  4       ^*4       R#   + '       g   i     L2; i$   Nr3   r!   ri   r   s   r   r   ?ContextTest.test_token_contextmanager_with_default.<locals>.fun  sK    r  "-  QUUWb) s   !A&&A6	Nr   r'   r   r   r(   s   f  @r   &test_token_contextmanager_with_default2ContextTest.test_token_contextmanager_with_default  s5    !!#""33	* 	r   c                   a a \         P                  ! 4       p\         P                  ! R 4      oVV 3R lpVP                  V4       R# )r(   c                  H  < S P                  ^$4      ;_uu_ 4        SP                  S P                  4       ^$4       RRR4       SP                  \        R4      ;_uu_ 4        S P                  4        RRR4       R#   + '       g   i     LI; i  + '       g   i     R# ; i)r)  Nz<ContextVar name='c')r3   r!   ri   r   r   r   s   r   r   BContextTest.test_token_contextmanager_without_default.<locals>.fun  sh    r  "-  ''5KLL ML  MLLs   !A="B=B	B!	Nr   r,  s   f  @r   )test_token_contextmanager_without_default5ContextTest.test_token_contextmanager_without_default  s3    !!#""3'	 	r   c                
  a a \         P                  ! 4       p\         P                  ! R ^*R7      oVV 3R lpS P                  \        R4      ;_uu_ 4        VP                  V4       RRR4       R#   + '       g   i     R# ; i)r(   r-   c                     < S P                  ^$4      ;_uu_ 4        SP                  S P                  4       ^$4       \        R4      h  + '       g   i     M; iSP                  S P                  4       ^*4       R# )r)  custom exceptionN)r3   r!   ri   r   r   s   r   r   ?ContextTest.test_token_contextmanager_on_exception.<locals>.fun  sR    r  "- !344  QUUWb)s   ,AA	r6  N)r   r   r    r   r   r   r,  s   f  @r   &test_token_contextmanager_on_exception2ContextTest.test_token_contextmanager_on_exception  sY    !!#""33	* ##J0BCCGGCL DCCCs   A11B	c                   a a \         P                  ! 4       p\         P                  ! R ^*R7      oVV 3R lpVP                  V4       R# )r(   r-   c                    < SP                  ^$4      p SP                  \        R4      ;_uu_ 4        T ;_uu_ 4        V ;_uu_ 4        SP                  SP	                  4       ^$4       RRR4       RRR4       RRR4       SP                  SP	                  4       ^*4       R#   + '       g   i     LB; i  + '       g   i     LM; i  + '       g   i     LX; i)r)  $<Token .+ has already been used onceN)r3   r   r   r!   ri   tokenr(   r'   s    r   r   <ContextTest.test_token_contextmanager_reentrant.<locals>.fun  s    EE"IE'' :  U(("5  	 QUUWb)  U	 s:   CB5	!B"(B5	0C"B2-B5	5C CC	Nr   r,  s   f  @r   #test_token_contextmanager_reentrant/ContextTest.test_token_contextmanager_reentrant  s5    !!#""33
	* 	r   c                   a a \         P                  ! 4       p\         P                  ! R ^*R7      oVV 3R lpVP                  V4       R# )r(   r-   c                    < S P                  ^$4      ;_uu_ 4        SP                  S P                  4       ^$4       S P                  ^4       SP                  S P                  4       ^4       S P                  ^4       SP                  S P                  4       ^4       RRR4       SP                  S P                  4       ^*4       R#   + '       g   i     L2; ir(  r*  r   s   r   r   AContextTest.test_token_contextmanager_multiple_c_set.<locals>.fun  s    r  "-b	  "-b	  "-  QUUWb)    BCC	Nr   r,  s   f  @r   (test_token_contextmanager_multiple_c_set4ContextTest.test_token_contextmanager_multiple_c_set  s5    !!#""33	* 	r   c                   a a \         P                  ! 4       p\         P                  ! R ^*R7      oVV 3R lpVP                  V4       R# )r(   r-   c            	        < SP                  \        R 4      ;_uu_ 4        SP                  ^$4      ;_uu_ 4       p SP                  SP	                  4       ^$4       SP                  V 4       SP                  SP	                  4       ^*4       RRR4       RRR4       SP                  SP	                  4       ^*4       R#   + '       g   i     L:; i  + '       g   i     LE; i)r<  N)r   r   r3   r!   ri   r5   r=  s    r   r   UContextTest.test_token_contextmanager_with_explicit_reset_the_same_token.<locals>.fun  s    '' :  UU2YY%$$QUUWb1GGEN$$QUUWb1	 	 QUUWb) Y	 s#   CAB>	C>C	CC!	Nr   r,  s   f  @r   <test_token_contextmanager_with_explicit_reset_the_same_tokenHContextTest.test_token_contextmanager_with_explicit_reset_the_same_token  s5    !!#""33	* 	r   c                   a a \         P                  ! 4       p\         P                  ! R ^*R7      oVV 3R lpVP                  V4       R# )r(   r-   c                    < SP                  ^$4      ;_uu_ 4        SP                  SP                  4       ^$4       SP                  ^4      p SP                  SP                  4       ^4       SP                  V 4       SP                  SP                  4       ^$4       RRR4       SP                  SP                  4       ^*4       R#   + '       g   i     L2; ir(  )r3   r!   ri   r5   r=  s    r   r   TContextTest.test_token_contextmanager_with_explicit_reset_another_token.<locals>.fun"  s    r  "-b	  "-  "-  QUUWb) rE  Nr   r,  s   f  @r   ;test_token_contextmanager_with_explicit_reset_another_tokenGContextTest.test_token_contextmanager_with_explicit_reset_another_token  s5    !!#""33		* 	r   rB   N)(rD   rE   rF   rG   r)   r   r8   r=   rR   rW   rf   rk   rp   rs   r   r   r   r   r   r   r   r   r   r   r   r   r   r   requires_working_threadingr  r$  r-  r2  r8  r@  rF  rK  rP  rH   ra   rb   s   @r   r   r      sa    2 ) )& D D"08$8' ) )0) 3) 3)j    0   
& 
&2> 0023 3 3" 0022 3 2h
$ & r   r   c                   D   a  ] tR tRt o RtRR/R ltR tR tR tRt	V t
R# )	HashKeyi3  Nerror_on_eq_toc               *    W n         Wn        W0n        R # r	   )r"   r&   rU  )r'   r&   r"   rU  s   &&&$r   __init__HashKey.__init__6  s    		,r   c                <    R V P                    RV P                   R2# )z
<Key name:z hash:>)r"   r&   rV   s   &r   __repr__HashKey.__repr__<  s    DII;fTYYKq99r   c                z    V P                   e#   V P                   P                  '       d   \        hV P                  # r	   )_crashererror_on_hashHashingErrorr&   rV   s   &r   __hash__HashKey.__hash__?  s+    ==$)D)D)Dyyr   c                   \        V\        4      '       g   \        # V P                  e#   V P                  P                  '       d   \
        hV P                  e$   V P                  VJ d   \        RV : RV: 24      hVP                  e$   VP                  V J d   \        RV: RV : 24      hV P                  V P                  3VP                  VP                  38H  # )Nzcannot compare z to )

isinstancerT  NotImplementedr^  error_on_eqEqErrorrU  r   r"   r&   r]   s   &&r   r_   HashKey.__eq__E  s    %))!!==$)B)B)BM*t/B/Be/Kthd5)DEE+0D0D0LuitD8DEE		499%%**ejj)AAAr   )rU  r&   r"   )rD   rE   rF   rG   r^  rW  r[  ra  r_   rH   ra   rb   s   @r   rT  rT  3  s,     H-T -:B Br   rT  c                   >   a a ] tR tRt oV 3R ltV 3R ltRtVtV ;t# )KeyStriT  c                   < \         P                  e'   \         P                  P                  '       d   \        h\        SV `  4       # r	   )rT  r^  r_  r`  superra  )r'   	__class__s   &r   ra  KeyStr.__hash__U  s4    'G,<,<,J,J,Jw!!r   c                   < \         P                  e'   \         P                  P                  '       d   \        h\        SV `  V4      # r	   )rT  r^  rf  rg  rl  r_   )r'   r^   rm  s   &&r   r_   KeyStr.__eq__Z  s4    'G,<,<,H,H,HMw~e$$r   rB   )	rD   rE   rF   rG   ra  r_   rH   ra   __classcell__)rm  rc   s   @@r   rj  rj  T  s     "
% %r   rj  c                   >   a  ] tR tRt o RRRR/R ltR tR tRtV tR	# )
HaskKeyCrasheri`  r_  Frf  c                   Wn         W n        R # r	   )r_  rf  )r'   r_  rf  s   &$$r   rW  HaskKeyCrasher.__init__a  s    *&r   c                V    \         P                  e   \        R4      hV \         n        R # )Nzcannot nest crashers)rT  r^  r   rV   s   &r   	__enter__HaskKeyCrasher.__enter__e  s"    '566r   c                    R \         n        R # r	   )rT  r^  )r'   excs   &*r   __exit__HaskKeyCrasher.__exit__j  s
    r   )rf  r_  N)	rD   rE   rF   rG   rW  rw  r{  rH   ra   rb   s   @r   rs  rs  `  s'     ' '5 ' 
   r   rs  c                       ] tR tRtRtR# )r`  in  rB   NrC   rB   r   r   r`  r`  n      r   r`  c                       ] tR tRtRtR# )rg  ir  rB   NrC   rB   r   r   rg  rg  r  r~  r   rg  z&_testinternalcapi.hamt() not availablec                      a  ] tR tRt o R tR tR tR tR tR t	R t
]P                  ! R	4      R
 4       tR tR tR tR tR tR tR tR tR tR tR tR tR tR tR tRtV tR# )HamtTestiv  c                $   \        ^
R4      p\        ^
R4      pV P                  W4       V P                  \        V4      \        V4      4       \	        4       pRW1&   RW2&   V P                  W1,          R4       V P                  W2,          R4       R# )r   r   r   r,   bN)rT  r%   r!   r&   dict)r'   k1k2ds   &   r   test_hashkey_helper_1HamtTest.test_hashkey_helper_1y  sy    RRB#b48,F$$r   c                    \        4       pR pR # r	   r   r'   hs   & r   test_hamt_basics_1HamtTest.test_hamt_basics_1  s    Fr   c                @   \        4       pV P                  \        V4      ^ 4       VP                  RR4      pV P	                  W4       V P                  \        V4      ^ 4       V P                  \        V4      ^4       V P                  VP                  R4      4       V P                  VP                  R^*4      ^*4       V P                  VP                  R4      R4       VP                  R^
4      pV P	                  W#4       V P                  \        V4      ^ 4       V P                  \        V4      ^4       V P                  \        V4      ^4       V P                  VP                  R4      R4       V P                  VP                  R4      ^
4       V P                  VP                  R4      4       V P                  VP                  R4      4       V P                  VP                  R4      4       V P                  VP                  R4      R4       R;p;r#R# )r   r,   r  N)r   r!   r   r3   assertIsNotr   ri   )r'   r  h2h3s   &   r   test_hamt_basics_2HamtTest.test_hamt_basics_2  s   FQ#UU3_Q#R!$!%%*%sB,c*VVC_ Q#R!$R!$c*b)!%%*%"&&+&!%%*%c*Br   c                    \        4       p\        4       pVP                  R V4      pVP                  R V4      pV P                  W44       R# )1N)r   objectr3   r   )r'   r  oh1r  s   &    r   test_hamt_basics_3HamtTest.test_hamt_basics_3  s:    FHUU3]VVC^br   c                P   \        4       pVP                  R . 4      pVP                  R . 4      pV P                  W#4       V P                  \	        V4      ^4       V P                  \	        V4      ^4       V P                  VP                  R 4      VP                  R 4      4       R# )keyN)r   r3   r  r!   r   ri   )r'   r  r  r  s   &   r   test_hamt_basics_4HamtTest.test_hamt_basics_4  s    FUU5"VVE2 R!$R!$u6r   c                   \        ^
R4      p\        ^
R4      p\        ^
R4      p\        4       pVP                  VR4      pVP                  VR4      pV P                  VP	                  V4      R4       V P                  VP	                  V4      R4       V P                  VP	                  V4      R4       V P                  VP	                  V4      R4       V P                  VP	                  V4      R4       V P                  VP	                  V4      R4       VP                  VR4      pVP                  VR4      pV P                  VP	                  V4      R4       V P                  VP	                  V4      R4       V P                  VP	                  V4      R4       V P                  VP	                  V4      R4       V P                  VP	                  V4      R4       V P                  VP	                  V4      R4       V P                  VP	                  V4      R4       V P                  VP	                  V4      R4       V P                  VP	                  V4      R4       V P                  \        V4      ^ 4       V P                  \        V4      ^4       V P                  \        V4      ^4       V P                  \        V4      ^4       V P                  \        V4      ^4       R# )	r   r   r   cccr,   r  Nccr   )rT  r   r3   r!   ri   r   )	r'   r  r  k3r  r  r  h4h5s	   &        r   test_hamt_collision_1HamtTest.test_hamt_collision_1  s7   RRRFUU2s^VVB_rD)rD)S)T*S)S)VVBVVBS)S)S)T*T*S)T*T*T*Q#R!$R!$R!$R!$r   c                N   \        R R4      p\        R R4      p\        ^ R4      p\        4       pVP                  VR4      pVP                  VR4      pVP                  VR4      pT P                  VP	                  4        Uu0 uF  qUP
                  kK  	  up0 Rm4       R# u upi )l        CDEN>   r  r  r  )rT  r   r3   r!   r   r"   )r'   r  r  r  r  ks   &     r   test_hamt_collision_3HamtTest.test_hamt_collision_3  s     93?93?93?FEE!SMEE!SMEE!SM* 	!&&(3(Q&&(3_E3s   B"cpuc                @   R pRp^ap^p^p\        V4       EFc  p\        4       p\        4       p\        V4       EF  p	\        V	4      p
W,          '       gU   \	        RR7      ;_uu_ 4        V P                  \        4      ;_uu_ 4        VP                  W4       RRR4       RRR4       VP                  W4      pW,          '       g^   \	        RR7      ;_uu_ 4        V P                  \        4      ;_uu_ 4        VP                  \        V	4      4       RRR4       RRR4       WV
&   V P                  \        V4      \        V4      4       W,          '       d   EK&  V P                  \        VP                  4       4      \        VP                  4       4      4       V P                  \        VP                  4       4      \        VP                  4       4      4       EK  	  V P                  \        V4      V4       \        V4       F.  p
V P                  VP                  \        V
4      R4      V
4       K0  	  \        \        V4      4      p\        P                  ! V4       \!        V4       EF  w  r\        V	4      p
W,          '       gU   \	        RR7      ;_uu_ 4        V P                  \        4      ;_uu_ 4        VP#                  V
4       RRR4       RRR4       W,          '       g^   \	        RR7      ;_uu_ 4        V P                  \        4      ;_uu_ 4        VP#                  \        V	4      4       RRR4       RRR4       VP#                  V
4      pV P                  VP                  V
R4      R4       W V P                  \        V4      \        V4      4       W^,          8X  d   TpVP%                  4       pW,          '       d   EKg  V P                  \        VP'                  4       4      \        VP'                  4       4      4       V P                  \        VP'                  4       4      \        VP'                  4       4      4       EK  	  V P                  \        V4      ^ 4       V P                  \        V4      ^ 4       X F3  p
V P                  XP                  \)        V
4      4      W,          4       K5  	  V P                  \        V4      \        X4      4       \!        V4       EF  w  rVP#                  \)        V
4      4      pV P                  VP                  \)        V
4      R4      R4       VP+                  \)        V
4      R4       V P                  \        V4      \        V4      4       W,          '       d   K  V P                  \        VP-                  4       4      \        VP-                  4       4      4       V P                  \        VP-                  4       4      \        VP-                  4       4      4       EK  	  V P                  \        V4      ^ 4       V P                  \        V4      ^ 4       V P                  \        VP                  4       4      . 4       EKf  	  R#   + '       g   i     EL; i  + '       g   i     EL; i  + '       g   i     EL; i  + '       g   i     EL; i  + '       g   i     EL; i  + '       g   i     EL; i  + '       g   i     EL; i  + '       g   i     EL; i)iX  i  Tr_  Nrf  z	not found)r   r   r  rj  rs  r#   r`  r3   rg  ri   r!   r   r   r   r   shuffle	enumeratedeleter   r   re   popr   )r'   COLLECTION_SIZETEST_ITERS_EVERYCRASH_HASH_EVERYCRASH_EQ_EVERY
RUN_XTIMES_r  r  r   r  keys_to_deleteiter_ihmdms   &              r   test_hamt_stressHamtTest.test_hamt_stress  s   
z"AAA?+Qi,,'d;;!..|<<EE#M = < EE#M**'D99!..w77EE&), 8 : #  QQ0,,$$S^S^D$$S^S^D) ,, SV_5_-  vc{K!@#F . "%"89NNN>*&~6	Qi11'd;;!..|<<HHSM = < //'D99!..w77HHVAY/ 8 : HHSM  sK!8+FF  QQ011BB11$$S]CMB$$S]CMB1 74 SVQ'SVQ'   C!127; SWc"g.#N3YYs3x(  C+!>Ls3x&  QQ0,,$$S_c!((*oF$$S_c!((*oF 4 SVQ'SVQ'T!'')_b1a # =<< <;; 877 :99. =<< <;; 877 :99s   *Z	Z Z	Z<	;Z(Z<	$[$	[[$	\	$[8?\	 Z	Z	Z%(Z93	Z<	<[[!	[$	$[58\		\	\c                d   \        ^dR4      p\        ^eR4      p\        ^fR4      p\        ^gR4      p\        ^hR4      p\        RR4      p\        ^gRVR7      p\        4       pVP                  VR	4      pVP                  VR
4      pVP                  VR4      pVP                  VR4      pVP                  VR4      p\        V4      p	VP	                  V4      pV P                  \        V4      V	^,
          4       V P                  \        R4      ;_uu_ 4        VP	                  V4       RRR4       VP	                  V4      pV P                  \        V4      V	^,
          4       VP	                  V4      p
V P                  W4       VP	                  V4      pV P                  \        V4      V	^,
          4       V P                  VP                  V^*4      ^*4       V P                  VP                  V4      R
4       V P                  VP                  V4      R4       R#   + '       g   i     L; i)d   ABr  r  r  ZErrU  r,   r  r(   r  ecannot compareN)
rT  r   r3   r   r  r!   r   r   r   ri   )r'   r  r  r  r  r  r  r  r  orig_lenr  s   &          r   test_hamt_delete_1HamtTest.test_hamt_delete_1[  s   CCCCCD#S$q1FEE!SMEE!SMEE!SMEE!SMEE!SMq6 HHQKQA.##J0@AAHHRL B HHQKQA.XXa[bHHQKQA.q"r*q3'q3' BAs   HH/	c                   \        ^dR4      p\        RR4      p\        RR4      p\        ^gR4      p\        ^hR4      p\        RR4      p\        RR	VR
7      p\        4       pVP                  VR4      pVP                  VR4      pVP                  VR4      pVP                  VR4      pVP                  VR4      p\        V4      p	V P	                  \
        R4      ;_uu_ 4        VP                  V4       RRR4       VP                  V4      pV P                  \        V4      V	4       VP                  V4      pV P                  \        V4      V	^,
          4       VP                  V4      pV P                  \        V4      V	^,
          4       VP                  V4      pV P                  \        V4      V	^,
          4       V P                  VP                  V4      R4       V P                  VP                  V4      R4       VP                  V4      pVP                  V4      pVP                  V4      pVP                  V4      pV P                  \        V4      ^ 4       R#   + '       g   i     ELy; i)r  r  ) r  鉊 r  r  r  r  r  r  r,   r  r(   r  r  r  Nr  )	rT  r   r3   r   r   r   r  r!   ri   )
r'   r  r  r  r  r  r  r  r  r  s
   &         r   test_hamt_delete_2HamtTest.test_hamt_delete_2  s   CFC FC CCD#VT!4FEE!SMEE!SMEE!SMEE!SMEE!SMq6 ##J0@AAHHRL B HHQKQ*HHQKQA.HHQKQA.HHQKQA.q3'q3'HHQKHHQKHHQKHHQKQ#- BAAs   $I&&I7	c                   \        ^dR4      p\        ^eR4      p\        RR4      p\        RR4      p\        ^hR4      p\        4       pVP                  VR4      pVP                  VR4      pVP                  VR	4      pVP                  VR
4      pVP                  VR4      p\        V4      pVP	                  V4      pV P                  \        V4      V^,
          4       VP	                  V4      pV P                  \        V4      V^,
          4       V P                  VP                  V4      R	4       V P                  VP                  V4      R4       R# r  r  r   r  r  r  r,   r  r(   r  r  N)rT  r   r3   r   r  r!   ri   r'   r  r  r  r  r  r  r  s   &       r   test_hamt_delete_3HamtTest.test_hamt_delete_3  s   CCFC FC CFEE!SMEE!SMEE!SMEE!SMEE!SMq6 HHQKQA.HHQKQA.q3'q3'r   c                L   \        ^dR4      p\        ^eR4      p\        RR4      p\        RR4      p\        RR4      p\        4       pVP                  VR4      pVP                  VR4      pVP                  VR	4      pVP                  VR
4      pVP                  VR4      p\        V4      pVP	                  V4      pV P                  \        V4      V^,
          4       VP	                  V4      pV P                  \        V4      V^,
          4       VP	                  V4      pV P                  \        V4      V^,
          4       VP	                  V4      pV P                  \        V4      V^,
          4       VP	                  V4      pV P                  \        V4      ^ 4       R# r  )rT  r   r3   r   r  r!   r  s   &       r   test_hamt_delete_4HamtTest.test_hamt_delete_4  sP   CCFC FC FC FEE!SMEE!SMEE!SMEE!SMEE!SMq6 HHQKQA.HHQKQA.HHQKQA.HHQKQA.HHQKQ#r   c                   \        4       p. p\        ^4       F>  p\        V\        V4      4      pVP	                  V4       VP                  VRV 24      pK@  	  \        ^R4      pVP                  VR4      pV P                  \        V4      ^4       VP                  V^,          4      pV P                  \        V4      ^4       VP                  V4      pV P                  \        V4      ^4       VP                  V^,          4      pV P                  \        V4      ^4       VP                  V^,          4      pV P                  \        V4      ^4       VP                  V^,          4      pV P                  \        V4      ^4       V F  pVP                  V4      pK  	  V P                  \        V4      ^ 4       R# )   zval-18	collisionN)	r   r   rT  re   r2   r3   r!   r   r  )r'   r  r   r   r  collision_key16s   &     r   test_hamt_delete_5HamtTest.test_hamt_delete_5
  sg   FrA!SV$CKKcT!:&A 
 ""d+EE/;/( 	Q$HHT!WQ$HH_%Q$HHT"XQ$HHT!WQ$HHT!WQ$CA Q#r   c           
        \        ^dR4      p\        RR4      p\        RR4      p\        ^gR4      p\        ^hR4      p\        ^nR4      p\        4       pVP                  VR	4      pVP                  VR
4      pVP                  VR4      pVP                  VR4      pVP                  VR4      pVP                  VR4      pVP                  4       pV P	                  \        \        V4      4      VR	3VR
3VR3VR3VR3VR304       R# )r  r  r  r  r  r  r  r  Fr,   r  r(   r  r  r   NrT  r   r3   r   r!   r   	r'   r  r  r  r  r  r  r  its	   &        r   test_hamt_items_1HamtTest.test_hamt_items_1;  s    CFC FC CCCFEE!SMEE!SMEE!SMEE!SMEE!SMEE!SMWWYRMX3x!SAs8aX3xH	Jr   c           
        \        ^dR4      p\        ^eR4      p\        RR4      p\        RR4      p\        RR4      p\        ^nR4      p\        4       pVP                  VR4      pVP                  VR	4      pVP                  VR
4      pVP                  VR4      pVP                  VR4      pVP                  VR4      pVP                  4       pV P	                  \        \        V4      4      VR3VR	3VR
3VR3VR3VR304       R# r  r  r  r  r  r  r  r  r,   r  r(   r  r  r   Nr  r  s	   &        r   test_hamt_items_2HamtTest.test_hamt_items_2P  s    CCFC FC FC CFEE!SMEE!SMEE!SMEE!SMEE!SMEE!SMWWYRMX3x!SAs8aX3xH	Jr   c           	     :   \        ^dR4      p\        ^eR4      p\        RR4      p\        RR4      p\        RR4      p\        ^nR4      p\        4       pVP                  VR4      pVP                  VR	4      pVP                  VR
4      pVP                  VR4      pVP                  VR4      pVP                  VR4      pV P                  \        \	        VP                  4       4      4      WW4WV04       V P                  \        \	        V4      4      WW4WV04       R# r  )rT  r   r3   r!   r   r   )r'   r  r  r  r  r  r  r  s   &       r   test_hamt_keys_1HamtTest.test_hamt_keys_1e  s    CCFC FC FC CFEE!SMEE!SMEE!SMEE!SMEE!SMEE!SMT!&&(^,qQ1.@AT!WaA'9:r   c                    \        4       pV P                  \        VP                  4       4      ^ 4       V P                  \	        VP                  4       4      . 4       R# r   )r   r!   r   r   r   r  s   & r   test_hamt_items_3HamtTest.test_hamt_items_3x  s=    FQWWY+aggi"-r   c                   \        ^dR4      p\        ^eR4      p\        RR4      p\        RR4      p\        ^xR4      p\        4       pVP                  VR4      pVP                  VR4      pVP                  VR	4      pVP                  VR
4      p\        4       pVP                  VR4      pV P                  Wg8H  4       V P	                  Wg8g  4       VP                  VR4      pV P                  Wg8H  4       V P	                  Wg8g  4       VP                  VR	4      pV P                  Wg8H  4       V P	                  Wg8g  4       VP                  VR4      pV P                  Wg8H  4       V P	                  Wg8g  4       VP                  VR
4      pV P	                  Wg8H  4       V P                  Wg8g  4       VP                  VR4      pV P                  Wg8H  4       V P	                  Wg8g  4       VP                  V4      pV P                  Wg8H  4       V P	                  Wg8g  4       VP                  VR
4      pV P                  Wg8H  4       V P	                  Wg8g  4       R# )r  r  r  r  r  r  r  r,   r  r(   r  d2r  N)rT  r   r3   assertFalser   r  )r'   r  r  r  r  r  r  r  s   &       r   test_hamt_eq_1HamtTest.test_hamt_eq_1}  s   CCFC FC CVVVAs^VVAs^VVAs^VVAs^VVVAs^"!VVAs^"!VVAs^"!VVAt_"!VVAs^!"VVAs^"!YYq\"!VVAs^"!r   c                   \        ^dR4      p\        ^dRVR7      p\        4       pVP                  VR4      p\        4       pVP                  VR4      pV P                  \        R4      ;_uu_ 4        W48H   RRR4       V P                  \        R4      ;_uu_ 4        W48g   RRR4       R#   + '       g   i     L=; i  + '       g   i     R# ; i)r  r  r  r  r,   r  N)rT  r   r3   r   r   )r'   r  r  r  r  s   &    r   test_hamt_eq_2HamtTest.test_hamt_eq_2  s    CS$q1VVVAs^VVVB_##J0@AAH B ##J0@AAH BA BA BAAs   1B+B>+B;	>C	c                   \        ^dR4      p\        4       pVP                  ^ ^ 4      p\        P                  ! V4      p. pVP                  V4       VP                  V4       . pVP                  V4       VP                  V4       VP                  W4      p???\        P                  ! 4        \        P                  ! 4        \        P                  ! 4        V P                  V! 4       4       R# )r  r  N)	rT  r   r3   weakrefrefr2   gccollectr   )r'   r  r  r   r,   r  s   &     r   test_hamt_gc_1HamtTest.test_hamt_gc_1  s    CFEE!QKkk!n				EE!Kq!








#% r   c                   \        ^dR4      p\        ^eR4      p\        4       pVP                  VR4      pVP                  W4      p\        P                  ! V4      pVP                  4       p\        V4       ??\        P                  ! 4        \        P                  ! 4        \        P                  ! 4        V P                  V! 4       4       R# )r  r  r  r,   N)
rT  r   r3   r  r   r   nextr  r  r   )r'   r  r  r  r   his   &     r   test_hamt_gc_2HamtTest.test_hamt_gc_2  s    CCFEE!SMEE!Kkk!nWWYRr








#% r   c           	        \        ^dR4      p\        ^dR4      p\        ^eR4      p\        4       pVP                  V^4      pV P                  W9   4       V P	                  W49   4       V P                  \        4      ;_uu_ 4        \        RR7      ;_uu_ 4        W$9    RRR4       RRR4       V P                  \        4      ;_uu_ 4        \        RR7      ;_uu_ 4        W$9    RRR4       RRR4       R#   + '       g   i     La; i  + '       g   i     Ll; i  + '       g   i     L@; i  + '       g   i     R# ; i)r  r  r  Tr  Nr  )	rT  r   r3   r   r  r#   rg  rs  r`  r'   r  AAr  r  s   &    r   test_hamt_in_1HamtTest.test_hamt_in_1  s    CS#CFEE!QK w''D11 2 ( |,,d33 4 -, 21 ('
 43 -,,sH   D
C7	D
D0 D	%D07DD

D	D-(D00E	c           	     .   \        ^dR4      p\        ^dR4      p\        ^eR4      p\        4       pVP                  V^4      pV P                  WA,          ^4       V P                  WB,          ^4       V P	                  \
        4      ;_uu_ 4        WC,           RRR4       V P	                  \        4      ;_uu_ 4        \        RR7      ;_uu_ 4        WB,           RRR4       RRR4       V P	                  \        4      ;_uu_ 4        \        RR7      ;_uu_ 4        WB,           RRR4       RRR4       R#   + '       g   i     L; i  + '       g   i     Lx; i  + '       g   i     L; i  + '       g   i     LS; i  + '       g   i     R# ; i)r  r  r  NTr  r  )	rT  r   r3   r!   r#   r   rg  rs  r`  r  s   &    r   test_hamt_getitem_1HamtTest.test_hamt_getitem_1  s   CS#CFEE!QKq!"x((D ) w''D11 2 ( |,,d33 4 -, )( 21 ('
 43 -,,sT   	D7<E	E
	EF	E0	%F7E	
EEE-	0F ;FF	rB   N)rD   rE   rF   rG   r  r  r  r  r  r  r  r   requires_resourcer  r  r  r  r  r  r  r  r  r  r  r  r  r  r  r  rH   ra   rb   s   @r   r  r  v  s     %<7#%J!FF u%W2 &W2r+(Z2$h"(H($T/$bJ*J*;&.
-"^ !.!(( r   r  __main__)!r
  collections.abcr   concurrent.futuresr   r   r   r  r   r   unittestr  testr   test.supportr   _testinternalcapir   ImportErrorr   TestCaser   rT  re   rj  rs  	Exceptionr`  rg  skipIfr  rD   mainrB   r   r   <module>r     s    
     	      )&
P(## PlB BB	%S 	%   	9 		i 	 
GHY
x   Y
 IY
x zMMO G(  Ds   C 	CC