U
    ÎZjZ  ã                   @   sh   d dl mZ d dlZd dlmZ d dlmZ dd„ Zdd„ Z	dd	„ Z
d
d„ Zdd„ Zdd„ Zdd„ ZdS )é    )ÚdedentN)Ú	deprecatec                   C   s   dS )zŽ
    This is the summary. The deprecate directive goes next.

    This is the extended summary. The deprecate directive goes before this.
    únew_func called© r   r   r   úc/var/www/html/TRUCKING_PROJECT/venv/lib/python3.8/site-packages/pandas/tests/util/test_deprecate.pyÚnew_func
   s    r   c                   C   s   dS )Núnew_func_no_docstring calledr   r   r   r   r   Únew_func_no_docstring   s    r	   c                   C   s   dS )z#Summary should be in the next line.znew_func_wrong_docstring calledr   r   r   r   r   Únew_func_wrong_docstring   s    r
   c                   C   s   dS )zÅ
    This is the summary. The deprecate directive goes next.

    .. deprecated:: 1.0
        Use new_func instead.

    This is the extended summary. The deprecate directive goes before this.
    Nr   r   r   r   r   Únew_func_with_deprecation   s    	r   c               	   C   sP   t dtddd�} t t¡� | ƒ }W 5 Q R X |dks8t‚| jttjƒksLt‚d S )NÚ	depr_funcú1.0úUse new_func instead.©Úmsgr   )	r   r   ÚtmÚassert_produces_warningÚFutureWarningÚAssertionErrorÚ__doc__r   r   ©r   Úresultr   r   r   Útest_deprecate_ok(   s
    r   c               	   C   s<   t dtddd�} t t¡� | ƒ }W 5 Q R X |dks8t‚d S )Nr   r   r   r   r   )r   r	   r   r   r   r   r   r   r   r   Útest_deprecate_no_docstring2   s       ÿr   c               	   C   s2   d} t jt| d�� tdtddd� W 5 Q R X d S )Nz/deprecate needs a correctly formatted docstring)Úmatchr   r   r   r   )ÚpytestZraisesr   r   r
   r   r   r   r   Útest_deprecate_wrong_docstring;   s       ÿr   )Útextwrapr   r   Zpandas.util._decoratorsr   Zpandas._testingZ_testingr   r   r	   r
   r   r   r   r   r   r   r   r   Ú<module>   s   	
	