U
    luf                     @   s   d dl Z d dlZd dlZd dlZedZe jeZ	e j
e	dZejje je de dejjdejkddejjejdd	dejd
ddgdd ZdS )    N	pyximportzcython_ext.pyxzRequires cython test file )reasonzzmq.backend.cythonzRequires cython backendwinz#Don't try runtime Cython on Windowslanguage_level      c                    s~   dt jksttjtt d| t|d d } fdd}|	| ddl
m} t|ds`td	}||}||ksztd S )
Nzmq.tests.cython_ext)include_dirs)Z
setup_argsr   	build_dirc                      s   t j   tjdd  d S )Nr   )r   	uninstallsysmodulespop 	importersr   9/tmp/pip-unpacked-wheel-h6ekxre8/zmq/tests/test_cython.pyunimport$   s    
ztest_cython.<locals>.unimport   )
cython_extsend_recv_tests   my msg)r   r   AssertionErrorr   installdictzmqZget_includesstrZaddfinalizer r   hasattrr   )r   requestZtmpdirr   r   msgZreceivedr   r   r   test_cython   s    

r    )osr   Zpytestr   Zimportorskipr   pathdirname__file__ZHEREjoinr   markZskipifexistsr   platform
startswithZparametrizer    r   r   r   r   <module>   s(   
 
 