
    m7hh                        d dl mZ d dlmZ d dlZd dlZd dlmZmZ d dlZ	d dl
Z
d dlZd dlmZ ej                  rd dlmZ  ed      Ze
j$                  j'                  dg d	      	 	 	 	 	 	 dd
       ZddZd ZddZddZddZddZddZy)    )annotations)CallableN)AnyTypeVar)_api)SelfTztarget,shape_repr,test_shape))Nz(N,))      )Nr   (N, 3))r   )r   r   )r      ))r      z(1, 5))r   	   ))Nr   Nz	(M, 2, N))r   r   r   c           	        dt        j                  dt        |        d| d|       z   }t        j                  |      }t        j                  t        |      5  t        j                  | |       d d d        y # 1 sw Y   y xY w)N^z'aardvark' must be zD with shape z, but your input has shape match)aardvark)
reescapelennpzerospytestraises
ValueErrorr   check_shape)target
shape_repr
test_shapeerror_patterndatas        [C:\Users\ashis\OneDrive\Desktop\poolpix\venv\Lib\site-packages\matplotlib/tests/test_api.pytest_check_shaper&      st     "))
c&k]-
| DL	"# #M 88JD	z	7$/ 
8	7	7s   A<<Bc                 6    G d d      } t        j                  t        j                        5  | j                   d d d        t        j                  t        j                        5   |        }|j                   d d d        y # 1 sw Y   IxY w# 1 sw Y   y xY w)Nc                  \    e Zd Z ej                  d      ej
                  dd              Zy))test_classproperty_deprecation.<locals>.Az0.0.0c                     y r
    )clss    r%   fz+test_classproperty_deprecation.<locals>.A.f)   s         N)r,   r   returnNone)__name__
__module____qualname__r   
deprecatedclasspropertyr-   r+   r.   r%   Ar)   (   s-    		!				 
 
"	r.   r6   )r   warnsmplMatplotlibDeprecationWarningr-   )r6   as     r%   test_classproperty_deprecationr;   '   sd     
 
c66	7	 
8	c66	7C	 
8	7 
8	7	7	7s   B&BBBc            
        t        j                  t        j                  d      5  t	        j
                  dd       d d d        t        j                  t        j                  d      5  t	        j
                  ddd       d d d        t        j                  t        j                  d	      5  t	        j
                  ddd
       d d d        t        j                  t        j                  d      5  t	        j
                  ddd       d d d        t        j                  t        j                  d      5  t	        j
                  ddd       d d d        t        j                  t        j                  d      5  t	        j
                  ddd       d d d        t        j                  t        d      5  t	        j
                  ddd       d d d        t        j                  t        d      5  t	        j
                  dddd       d d d        t        j                  t        j                  d      5  t	        j
                  dddd
ddd       d d d        y # 1 sw Y   ,xY w# 1 sw Y   xY w# 1 sw Y   xY w# 1 sw Y   xY w# 1 sw Y   HxY w# 1 sw Y   xY w# 1 sw Y   xY w# 1 sw Y   xY w# 1 sw Y   y xY w)NzEfoo was deprecated in Matplotlib 3\.10 and will be removed in 3\.12\.r   z3.10foo)namezOThe foo class was deprecated in Matplotlib 3\.10 and will be removed in 3\.12\.class)r>   obj_typezWfoo was deprecated in Matplotlib 3\.10 and will be removed in 3\.12\. Use bar instead\.bar)r>   alternativezXfoo was deprecated in Matplotlib 3\.10 and will be removed in 3\.12\. More information\.zMore information.)r>   addendumzDfoo was deprecated in Matplotlib 3\.10 and will be removed in 4\.0\.z4.0)r>   removalz(foo was deprecated in Matplotlib 3\.10\.Fz*foo will be deprecated in a future versionT)r>   pendingzcannot have a scheduled removalz3.12)r>   rE   rD   zComplete replacement)messager>   rB   rC   r@   rD   )	r   r7   r8   r9   r   warn_deprecatedPendingDeprecationWarningr   r   r+   r.   r%   test_warn_deprecatedrI   4   s7   	c662
3 	V%0
3 
c66:
; 	V%'B
; 
c66D
E 	V%UC
E 
c66E
F 	V%:MN
F 
c661
2 	V%?
2 
c66G
IV%?
I 
/I
KV%>
K 
z)K	LV%vN 
M	c66>U	VV-C%).9L&-u	> 
W	V9
3 
3
; 
;
E 
E
F 
F
2 
2
I 
I
K 
K 
M	L	V	Vsk   I(+I51J7J=JJ)?J6;KK(I25I?JJJ&)J36J?KKc                 j    G d d      }  |        }t        j                  t        j                        5  |j                  dk(  sJ 	 d d d        t        j                  t        j                        5  d|_        d d d        t        j                  t        j                        5  |j                  dk(  sJ 	 d d d        t        j                  t        j                        5  |j                  d      dk(  sJ 	 d d d        y # 1 sw Y   xY w# 1 sw Y   xY w# 1 sw Y   exY w# 1 sw Y   y xY w)Nc                  z    e Zd ZU d	dZd
dZ ej                  d      Zded<    ej                  d      Z	ded<   y)-test_deprecate_privatize_attribute.<locals>.Cc                    d| _         y )Nr   )_attr)selfs    r%   __init__z6test_deprecate_privatize_attribute.<locals>.C.__init__Y   s    DJr.   c                    |S r
   r+   )rO   args     r%   _methz3test_deprecate_privatize_attribute.<locals>.C._methZ   s    Sjr.   z0.0intattrr   methNr/   r0   )rR   r	   r/   r	   )
r1   r2   r3   rP   rS   r   deprecate_privatize_attributerU   __annotations__rV   r+   r.   r%   CrL   X   s6    206D66u=c=;;;EBhBr.   rZ   r   r   *   )r   r7   r8   r9   rU   rV   )rZ   cs     r%   "test_deprecate_privatize_attributer]   W   s    C C 	
A	c66	7vv{{ 
8	c66	7 
8	c66	7vv{{ 
8	c66	7vvbzR 
8	7 
8	7	7	7	7	7	7	7s/   D3D&D$D)DDD&)D2c                    t        j                  dd      dd	d       t        j                  dd      d
d       } | fD ]>  } |        t        j                  t        j
                        5   |d       d d d        @ t         j                  j                  fd	fd} |        t        j                  t        j
                        5   d       d d d        y # 1 sw Y   xY w# 1 sw Y   y xY w)N3.0r=   c                     y r
   r+   r=   s    r%   func1z$test_delete_parameter.<locals>.func1j       r.   c                      y r
   r+   )kwargss    r%   func2z$test_delete_parameter.<locals>.func2n   rc   r.   rA   ra   c                     |        y r
   r+   )r=   rb   s    r%   pyplot_wrapperz-test_delete_parameter.<locals>.pyplot_wrapperw   s
    c
r.   r
   )r=   r   r/   r0   )re   r   r/   r0   )r   delete_parameterr   r7   r8   r9   deprecation_deprecated_parameter)rf   funcrh   rb   s      @r%   test_delete_parameterrm   i   s    	5%( ) 
5%( ) \\#::;UO <; 
 #'"2"2"H"H  	c66	7 
8	7 <; 
8	7s   .
C
C+C(	+C4c                 Z   t        j                  dd      dd	d       }  | dd       t        j                  t        j
                        5   | dd       d d d        t        j                  t        j
                        5   | ddd       d d d        y # 1 sw Y   @xY w# 1 sw Y   y xY w)
Nr_   rR   c                     y r
   r+   )prerR   posts      r%   rl   z$test_make_keyword_only.<locals>.func   rc   r.   r   r   )rR   r   r
   )rp   r   rR   r   rq   r   r/   r0   )r   make_keyword_onlyr   r7   r8   r9   )rl   s    r%   test_make_keyword_onlyrs      s    	E5) * 	N	c66	7Q
 
8	c66	7Q1 
8	7 
8	7	7	7s   
BB!B!B*c                     d} t        j                  d|       dd       }|j                  t        j                  d       | |j                  v sJ y )Nz)`.f1`, `f2`, `f3(x) <.f3>` or `f4(x)<f4>`1)rB   c                      y r
   r+   r+   r.   r%   r-   z'test_deprecation_alternative.<locals>.f   rc   r.   zDocumentation is disabledrW   )r   r4   __doc__r   skip)rB   r-   s     r%   test_deprecation_alternativery      sM    =K	__Sk2 3yy/0!))###r.   c                     t        j                  t        d      5  t        j                  dg       d d d        y # 1 sw Y   y xY w)NzNo argument to check!r   r:   )r   r   	TypeErrorr   check_in_listr+   r.   r%   test_empty_check_in_listr}      s.    	y(?	@C5! 
A	@	@s	   <A)r    ztuple[int | None, ...]r!   strr"   ztuple[int, ...]r/   r0   rW   )
__future__r   collections.abcr   r   typingr   r   numpyr   r   
matplotlibr8   r   TYPE_CHECKINGtyping_extensionsr   r	   markparametrizer&   r;   rI   r]   rm   rs   ry   r}   r+   r.   r%   <module>r      s    " $ 	       
&CL 70!$0!005900
 >F $,
$"r.   