Sindbad~EG File Manager

Current Path : /usr/local/lib/python3.9/test/__pycache__/
Upload File :
Current File : //usr/local/lib/python3.9/test/__pycache__/test_global.cpython-39.pyc

a

��g^�@sRdZddlmZmZddlZddlZGdd�dej�Zdd�Ze	dkrNe�
�dS)	zDVerify that warnings are issued for global statements following use.�)�check_syntax_error�check_warningsNc@s<eZdZdd�Zdd�Zdd�Zdd�Zd	d
�Zdd�Zd
S)�GlobalTestscCs$t�|_|j��tjddd�dS�N�error�
<test string>)�module)r�_warnings_manager�	__enter__�warnings�filterwarnings��self�r�,/usr/local/lib/python3.9/test/test_global.py�setUp
s
zGlobalTests.setUpcCs|j�ddd�dS)N)r	�__exit__r
rrr�tearDownszGlobalTests.tearDowncCsd}t||ddd�dS)Nz<def wrong1():
    a = 1
    b = 2
    global a
    global b
����lineno�offset�r)rZprog_text_1rrr�test1szGlobalTests.test1cCsd}t||ddd�dS)Nz(def wrong2():
    print(x)
    global x
�rrr)rZprog_text_2rrr�test2szGlobalTests.test2cCsd}t||ddd�dS)Nz2def wrong3():
    print(x)
    x = 2
    global x
rrrr)rZprog_text_3rrr�test3%szGlobalTests.test3cCsd}t|dd�dS)Nzglobal x
x = 2
r�exec)�compile)rZprog_text_4rrr�test4.szGlobalTests.test4N)	�__name__�
__module__�__qualname__rrrrrr rrrrrs
	rcCs4t��}|��t�|jddd�tjddd�dSr)r�catch_warningsr
�unittestZaddModuleCleanuprr)�cmrrr�setUpModule7sr'�__main__)�__doc__Ztest.supportrrr%rZTestCaserr'r!�mainrrrr�<module>s/

Sindbad File Manager Version 1.0, Coded By Sindbad EG ~ The Terrorists