a
    óñ"h 	  ã                   @   s®   d dl Z d dlZd dlZdd„ ZG dd„ dejƒZedkrªejdd@Ze	e j
ƒd	krlejd
e j
 ¡ d nejd
d W d  ƒ n1 sŒ0    Y  eD ]Zeejƒ qšdS )é    Nc                   C   s   t  dt¡ d S )NÚrw)ÚwarningsÚwarnÚRuntimeWarning© r   r   úD/opt/python-3.9.21/usr/lib/python3.9/unittest/test/_test_warnings.pyÚwarnfun   s    r   c                   @   sD   e Zd Zdd„ Zdd„ Zdd„ Zdd„ Zd	d
„ Zdd„ Zdd„ Z	dS )ÚTestWarningsc                 C   s(   |   dd¡ |   dd¡ |   dd¡ d S )Né   )ZassertEquals©Úselfr   r   r   Útest_assert   s    zTestWarnings.test_assertc                 C   s   |   d¡ |   d¡ d S )Né   T)Z
failUnlessr   r   r   r   Ú	test_fail   s    
zTestWarnings.test_failc                 C   s   |   dd¡ |  dd¡ d S )Nr
   é   é   )ZassertAlmostEqualZassertNotAlmostEqualr   r   r   r   Útest_other_unittest    s    z TestWarnings.test_other_unittestc                 C   s(   t  dt¡ t  dt¡ t  dt¡ d S )NZdw)r   r   ÚDeprecationWarningr   r   r   r   Útest_deprecation%   s    zTestWarnings.test_deprecationc                 C   s(   t  dt¡ t  dt¡ t  dt¡ d S )NÚiw)r   r   ÚImportWarningr   r   r   r   Útest_import*   s    zTestWarnings.test_importc                 C   s"   t  d¡ t  d¡ t  d¡ d S )NZuw)r   r   r   r   r   r   Útest_warning0   s    

zTestWarnings.test_warningc                 C   s   t ƒ  t ƒ  t ƒ  d S )N)r   r   r   r   r   Útest_function7   s    zTestWarnings.test_functionN)
Ú__name__Ú
__module__Ú__qualname__r   r   r   r   r   r   r   r   r   r   r   r	      s   r	   Ú__main__T)Úrecordr   F)Úexitr   )r   )ÚsysZunittestr   r   ZTestCaser	   r   Úcatch_warningsÚwsÚlenÚargvÚmainÚpopÚwÚprintÚmessager   r   r   r   Ú<module>   s   +*