
    daf                        d dl mZmZ d dlmZ d dlmZmZ dZdZ	dZ
dZ G d d	e      Zd
ZdZdez  Z G d dee      Z ed      Z ed      Z ed      Z G d dee      Z G d d      Z G d dee      Z G d dee      Zy)    )EnumIntEnum)isnan)PyTestCTest   l        l            l               @ c                       e Zd ZeZeZeZe	Z
y)BigNumN)__name__
__module____qualname__SMALLsmallBIGbigHUGEhugeREALLY_HUGEreally_huge     3/root/Python-3.12.4/Lib/test/test_json/test_enum.pyr
   r
   
   s    E
CDKr   r
   g
@g!	@   c                       e Zd ZeZeZeZy)FloatNumN)	r   r   r   EePIpiTAUtaur   r   r   r   r      s    	A	B
Cr   r   infz-infnanc                       e Zd ZeZeZeZy)WierdNumN)	r   r   r   INFr"   NEG_INFneg_infNANr#   r   r   r   r%   r%      s    
CG
Cr   r%   c                   0    e Zd Zd Zd Zd Zd Zd Zd Zy)TestEnumc                 6   t         D ]  }| j                  | j                  |      t        |j                               | j                  t        | j                  |            |       | j                  | j                  | j                  |            |        y N)r   assertEqualdumpsreprvaluefloatloadsselfenums     r   test_floatszTestEnum.test_floats$   su     	ADTZZ-tDJJ/?@U4::d#34d;TZZ

4(894@	Ar   c           
         t        t        d      D ]  \  }}| j                  | j                  |      |       t	        |      s[| j                  t        | j                  |            |       | j                  | j                  | j                  |            |       | j                  t	        t        | j                  |                         | j                  t	        | j                  | j                  |                          y )N)Infinity	-InfinityNaN)zipr%   r.   r/   r   r2   r3   
assertTrue)r5   r6   expecteds      r   test_weird_floatszTestEnum.test_weird_floats*   s    !(,LM 	END(TZZ-x8;  tzz$'7!8$?  DJJt,<!=tDeDJJt,<&= >?djjD1A&B CD	Er   c                 6   t         D ]  }| j                  | j                  |      t        |j                               | j                  t        | j                  |            |       | j                  | j                  | j                  |            |        y r-   )r
   r.   r/   strr1   intr3   r4   s     r   	test_intszTestEnum.test_ints4   st     	ADTZZ-s4::?SD!12D9TZZ

4(894@	Ar   c                    | j                  | j                  t        t                    t	        t
        t        t        t        g             | j                  | j                  | j                  t        t                          t        t                     | j                  | j                  t        t                    t	        t        t        t        g             | j                  | j                  | j                  t        t                          t        t                     | j                  | j                  t        t                    d       | j                  | j                  | j                  t        t                          d d t        t              d d        | j                  t!        | j                  | j                  t        t                          d                y )Nz[Infinity, -Infinity, NaN]r   )r.   r/   listr
   rA   r   r   r   r   r3   r   r   r   r    r%   r=   r   )r5   s    r   	test_listzTestEnum.test_list:   s<   DL1eS$<=	?DJJtF|$<=f	'DN3aS\*	,DJJtH~$>?h	)DN34	6DJJtH~$>?Ch+	-djjDN)CDQGHIr   c                    t         \  }}}}t        \  }}}t        \  }}	}
|d|d|d|d|d|d|d|d|	d	|
d
i
}| j                  | j	                  |            }| j                  |t        t                 d       | j                  |t        t                 d       | j                  |t        t                 d       | j                  |t        t                 d       | j                  |t        t                 d       | j                  |t        t                 d       | j                  |t        t                 d       | j                  |d   d       | j                  |d	   d	       | j                  |d
   d
       y )NtinylargelargerlargestzEuler's numberr   r!   r9   r:   r;   )r
   r   r%   r3   r/   r.   rA   r   r   r   r   r0   r   r   r    )r5   sbhrr   ptijndnds                r   test_dict_keyszTestEnum.test_dict_keysI   sW   
1a1a1afa8Qy$%j!K5
 ZZ

1&CJ0CHw/CI1C,-y9DG&67DHt,DI.J4K+6EE*r   c                    t        t        j                  t        j                  t        j                  t        j
                  t        j                  t        j                  t        j                  t        j                  t        j                  t        j                  
      }| j                  | j                  |            }| j!                  |d   t"               | j!                  |d   t$               | j!                  |d   t&               | j!                  |d   t(               | j!                  |d   t*               | j!                  |d   t,               | j!                  |d   t.               | j!                  |d	   t0               | j!                  |d
   t2               | j5                  t7        |d                y )N)
rH   rI   rJ   rK   r   r   r!   rR   rS   rT   rH   rI   rJ   rK   r   r   r!   rR   rS   rT   )dictr
   r   r   r   r   r   r   r   r!   r%   r"   r(   r#   r3   r/   r.   r   r   r   r   r   r   r    r&   r'   r=   r   )r5   rU   rV   s      r   test_dict_valueszTestEnum.test_dict_values^   s6   \\jj{{****;;LL,,"",, ZZ

1&FU+Gc*Ht,I4C!$D2&EC(C#&C'*bg'r   N)	r   r   r   r7   r?   rC   rF   rW   rZ   r   r   r   r+   r+   "   s$    AEAJ+*(r   r+   c                       e Zd Zy)
TestPyEnumNr   r   r   r   r   r   r\   r\   w       r   r\   c                       e Zd Zy)	TestCEnumNr]   r   r   r   r`   r`   x   r^   r   r`   N)r6   r   r   mathr   test.test_jsonr   r   r   r   r   r   r
   r   r   r    r2   r   r&   r'   r)   r%   r+   r\   r`   r   r   r   <module>rc      s      (	W  "fud 
 El
-Elud 
S( S(j )6 ( &% &r   