B
    ֐<[                 @   sN   d dl Z d dlZd dlmZ d dlmZ e eZdgZ	G dd dej
ZdS )    N)	format_tb)is_base_exceptionFailurec               @   s6   e Zd ZdZdZdddZdd Zdd	 Zd
d ZdS )r   zUnloadable or unexecutable test.

    A Failure case is placed in a test suite to indicate the presence of a
    test that could not be loaded or executed. A common example is a test
    module that fails to import.
    
    FNc             C   s<   t d||t| || _|| _|| _|| _tj	|  d S )NzA failure! %s %s %s)
logdebugr   	exc_classexc_valtb_addressunittestTestCase__init__)selfr   r   r	   address r   +lib/python3.7/site-packages/nose/failure.pyr      s    zFailure.__init__c             C   s   dt | jd| j| jf S )NzFailure: %s (%s)__name__)getattrr   r   )r   r   r   r   __str__   s    zFailure.__str__c             C   s   | j S )N)r
   )r   r   r   r   r   !   s    zFailure.addressc             C   sH   | j d k	r8t| jr"| j| j | | j| j n| | jd S )N)r	   r   r   with_tracebackr   )r   r   r   r   runTest$   s
    

zFailure.runTest)NN)	r   
__module____qualname____doc__Z__test__r   r   r   r   r   r   r   r   r      s   
)Zloggingr   	tracebackr   Znose.pyversionr   Z	getLoggerr   r   __all__r   r   r   r   r   r   <module>   s   
