ó
É~RSc           @   sL   d  Z  d d l m Z m Z d e f d „  ƒ  YZ d e f d „  ƒ  YZ d S(   sˆ  
This plugin installs a DEPRECATED error class for the :class:`DeprecatedTest`
exception. When :class:`DeprecatedTest` is raised, the exception will be logged
in the deprecated attribute of the result, ``D`` or ``DEPRECATED`` (verbose)
will be output, and the exception will not be counted as an error or failure.
It is enabled by default, but can be turned off by using ``--no-deprecated``.
iÿÿÿÿ(   t
   ErrorClasst   ErrorClassPlugint   DeprecatedTestc           B   s   e  Z d  Z RS(   s7   Raise this exception to mark a test as deprecated.
    (   t   __name__t
   __module__t   __doc__(    (    (    s6   lib/python2.7/site-packages/nose/plugins/deprecated.pyR      s   t
   Deprecatedc           B   s>   e  Z d  Z e Z e e d d d e ƒZ d „  Z	 d „  Z
 RS(   se   
    Installs a DEPRECATED error class for the DeprecatedTest exception. Enabled
    by default.
    t   labelt
   DEPRECATEDt	   isfailurec      
   C   s;   d } | j  d d d d d d | j | t ƒ d d	 ƒd
 S(   s&   Register commandline options.
        t   NOSE_WITHOUT_DEPRECATEDs   --no-deprecatedt   actiont
   store_truet   destt   noDeprecatedt   defaultt   helps6   Disable special handling of DeprecatedTest exceptions.N(   t
   add_optiont   gett   False(   t   selft   parsert   envt   env_opt(    (    s6   lib/python2.7/site-packages/nose/plugins/deprecated.pyt   options   s    c         C   s>   |  j  s d S| |  _ t | d t ƒ } | r: t |  _ n  d S(   s   Configure plugin.
        NR   (   t   can_configuret   conft   getattrR   t   enabled(   R   R   R   t   disable(    (    s6   lib/python2.7/site-packages/nose/plugins/deprecated.pyt	   configure%   s    		(   R   R   R   t   TrueR   R    R   R   t
   deprecatedR   R   (    (    (    s6   lib/python2.7/site-packages/nose/plugins/deprecated.pyR      s   				N(   R   t   nose.plugins.errorclassR    R   t	   ExceptionR   R   (    (    (    s6   lib/python2.7/site-packages/nose/plugins/deprecated.pyt   <module>   s   