Your IP : 216.73.216.213


Current Path : /opt/alt/python310/lib64/python3.10/distutils/tests/__pycache__/
Upload File :
Current File : //opt/alt/python310/lib64/python3.10/distutils/tests/__pycache__/test_msvccompiler.cpython-310.pyc

o

0�i�@s�dZddlZddlZddlZddlmZddlmZddlm	Z	ej
dkr'dndZe�edue�Gdd	�d	ej
ej��Zd
d�ZedkrKe	e��dSdS)
z"Tests for distutils._msvccompiler.�N)�DistutilsPlatformError)�support)�run_unittestZwin32zThese tests are only for win32c@s,eZdZdd�Zdd�Zdd�Zdd�Zd	S)
�msvccompilerTestCasecCsFddlm}dd�}|j}||_z|�t|jd�W||_dS||_w)NrcSsdS)N)NN�)Z	plat_specrr�H/opt/alt/python310/lib64/python3.10/distutils/tests/test_msvccompiler.py�_find_vcvarsallsz>msvccompilerTestCase.test_no_compiler.<locals>._find_vcvarsallzwont find this version)�distutils._msvccompiler�
_msvccompilerrZassertRaisesr�_get_vc_env)�selfr
rZold_find_vcvarsallrrr�test_no_compilers�z%msvccompilerTestCase.test_no_compilerc	Cs�ddlm}d}d}tj�dd�}|tj|<z)|�d�}|�|��|�|�|||���Wtj�|�|r>|tjd<dSdStj�|�|rM|tjd<w)NruṰḖṤṪ┅ṼẨṜu	₃⁴₅ZDISTUTILS_USE_SDKZx86)	r	r
�os�environ�poprZassertIn�lowerZassertEqual)rr
Ztest_varZ
test_valueZold_distutils_use_sdk�envrrr�test_get_vc_env_unicode#s 

��z,msvccompilerTestCase.test_get_vc_env_unicodecC�Hddlm}|��\}}|r|�|d�|�tj�|��dSt�	d��)Nr�zVS 2017 is not installed)
r	r
Z_find_vc2017�assertGreaterEqual�
assertTruer�path�isdir�unittest�SkipTest�rr
�versionrrrr�test_get_vc20175�
z$msvccompilerTestCase.test_get_vc2017cCr)Nr�zVS 2015 is not installed)
r	r
Z_find_vc2015rrrrrrrrrrr�test_get_vc2015Arz$msvccompilerTestCase.test_get_vc2015N)�__name__�
__module__�__qualname__r
rrr!rrrrrs
rcCs
t�t�S)N)rZ	makeSuiterrrrr�
test_suiteMs
r%�__main__)�__doc__�sysrrZdistutils.errorsrZdistutils.testsrZtest.supportr�platformZSKIP_MESSAGEZ
skipUnlessZTempdirManagerZTestCaserr%r"rrrr�<module>s$��>�