Файловый менеджер - Редактировать - /home/digitalm/venv/lib/python3.7/site-packages/numpy/f2py/tests/__pycache__/test_compile_function.cpython-37.pyc
Назад
B �5�g� � @ s� d Z ddlZddlZddlZddlmZ ddlZddlZddl m Z ddlmZ dd� Z ej�d d dgdd g�ejjdd�dd� ��Zdd� Zdd� Zej�dddg�dd� �ZdS )z0See https://github.com/numpy/numpy/pull/11937. � N)� import_module)�assert_equal� )�utilc C s( t �� st�d� t �� s$t�d� d S )NzNeeds C compilerzNeeds FORTRAN 77 compiler)r Zhas_c_compiler�pytest�skipZhas_f77_compiler� r r �\/home/digitalm-up/venv/lib/python3.7/site-packages/numpy/f2py/tests/test_compile_function.py�setup_module s r � extra_argsz--nooptz--debugz--noopt --debug� z$Imported module seems never deleted.)�reasonc C s� d}t �� }t �� }t�� }tj�|tt� � �d �}xv|d gD ]j}z"t� |� tjj ||| |d�}W d t� |� X t|d� tjdkr@t|�}|�� } t| d� tj|= q@W d S )NzT integer function foo() foo = 10 + 5 return end z.f)� modulenamer � source_fnr �win32� )r Zget_module_dirZget_temp_module_name�os�getcwd�path�join�str�uuid�uuid4�chdir�numpy�f2py�compiler �sys�platformr Zfoo�modules) r �fsourceZmoddir�modname�cwd�targetr �ret_valZreturn_checkZcalc_resultr r r �test_f2py_init_compile s( r% c C s t j�d�} t| d� d S )Ns invalidr )r r r r )r$ r r r �test_f2py_init_compile_failureV s r&