Your IP : 216.73.216.213


Current Path : /opt/alt/python39/lib64/python3.9/test/__pycache__/
Upload File :
Current File : //opt/alt/python39/lib64/python3.9/test/__pycache__/test_global.cpython-39.opt-2.pyc

a

XC?h^�@sNddlmZmZddlZddlZGdd�dej�Zdd�ZedkrJe�	�dS)�)�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�5/opt/alt/python39/lib64/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__)
Ztest.supportrrr%rZTestCaserr'r!�mainrrrr�<module>s/