B
    .(b                 @   sP   d dl mZ d dlmZ d dlZd dlmZ d dlmZ ddl	m
Z
 dd	 ZdS )
    )unicode_literals)VocabN)English)ensure_path   )make_tempdirc       	   	   C   s   t  }|j}t }t|d }| s0|  || t |}t	d|j
 tjd|d}t|d }| s||  || t|}|j
dkstW dQ R X dS )zTest that a new blank model can be made with a vocab from file,
    and that serialization does not drop the language at any point.vocablangen)r   ZnlpN)r   r   r   r   existsmkdirZto_diskr   Z	from_diskprintr	   spacyZblankloadAssertionError)	Zen_vocabZnlp1Zvocab1dZ	vocab_dirZvocab2Znlp2Znlp_dirZnlp3 r   T/home/dcms/DCMS/lib/python3.7/site-packages/spacy/tests/regression/test_issue4054.pytest_issue4054   s     


r   )
__future__r   Zspacy.vocabr   r   Zspacy.lang.enr   Z
spacy.utilr   utilr   r   r   r   r   r   <module>   s   