ó
[³XMc           @   sS   d  Z  d d l m Z d d l m Z d d l m Z d e j f d „  ƒ  YZ d S(   s-   
Tests for L{twisted.plugins.twisted_trial}.
iÿÿÿÿ(   t
   getPlugins(   t   unittest(   t	   IReportert   TestPluginsc           B   s    e  Z d  Z d „  Z d „  Z RS(   s-   
    Tests for Trial's reporter plugins.
    c         C   sa   g  t  t ƒ D] } | j | k r | ^ q } t | ƒ d k rY t d | | f ƒ ‚ n  | d S(   s±   
        Return the Trial reporter plugin with the given long option.

        If more than one is found, raise ValueError. If none are found, raise
        IndexError.
        i   s2   More than one plugin found with long option %r: %ri    (   R    R   t   longOptt   lent
   ValueError(   t   selft
   longOptiont   plugint   plugins(    (    sC   /usr/lib/python2.7/dist-packages/twisted/trial/test/test_plugins.pyt   getPluginsByLongOption   s    c         C   sr   |  j  d ƒ } |  j d | j ƒ |  j d | j ƒ |  j d | j ƒ |  j d | j ƒ |  j d | j ƒ d S(   sM   
        One of the reporter plugins is the subunit reporter plugin.
        t   subunits   Subunit Reporters   twisted.trial.reportert   SubunitReporterN(	   R   t   assertEqualst   namet   moduleR   t   assertIdenticalt   Nonet   shortOptt   klass(   R   t   subunitPlugin(    (    sC   /usr/lib/python2.7/dist-packages/twisted/trial/test/test_plugins.pyt   test_subunitPlugin%   s    (   t   __name__t
   __module__t   __doc__R   R   (    (    (    sC   /usr/lib/python2.7/dist-packages/twisted/trial/test/test_plugins.pyR      s   	N(	   R   t   twisted.pluginR    t   twisted.trialR   t   twisted.trial.itrialR   t   TestCaseR   (    (    (    sC   /usr/lib/python2.7/dist-packages/twisted/trial/test/test_plugins.pyt   <module>   s   