+
    Dfje                         R t ^ RIt^ RIHt ^ RIHt  ! R R]P                  4      t ! R R4      t ! R R	]P                  4      t	R# )
z
Sample test cases defined using the standard library L{unittest.TestCase}
class which are used as data by test cases which are actually part of the
trial test suite to verify handling of handling of such cases.
N)exc_info)Failurec                   b   a  ] tR t^t o R tR tR t]P                  ! R4      R 4       t	Rt
V tR# )
PyUnitTestc                    R# )z
A passing test.
N selfs   &@/usr/lib/python3/dist-packages/twisted/trial/test/pyunitcases.py	test_passPyUnitTest.test_pass           c                    \        R4      h)z5
A test which raises an exception to cause an error.
zpyunit error)	Exceptionr   s   &r
   
test_errorPyUnitTest.test_error   s     ''r   c                (    V P                  R4       R# )zA
A test which uses L{unittest.TestCase.fail} to cause a failure.
zpyunit failureN)failr   s   &r
   	test_failPyUnitTest.test_fail   s     			"#r   zpyunit skipc                    R# )zC
A test which uses the L{unittest.skip} decorator to cause a skip.
Nr   r   s   &r
   	test_skipPyUnitTest.test_skip"   r   r   r   N)__name__
__module____qualname____firstlineno__r   r   r   unittestskipr   __static_attributes____classdictcell____classdict__s   @r
   r   r      s1     
($ ]]=! "r   r   c                   6   a  ] tR t^)t o RtV 3R lR ltRtV tR# )_NonStringIdz
A class that looks a little like a TestCase, but not enough so to
actually be used as one.  This helps L{BrokenRunInfrastructure} use some
interfaces incorrectly to provoke certain failure conditions.
c                    < V ^8  d   QhRS[ /# )   returnobject)formatr#   s   "r
   __annotate___NonStringId.__annotate__0   s      F r   c                    \        4       # )Nr)   r   s   &r
   id_NonStringId.id0   s	    xr   r   N)r   r   r   r   __doc__r/   r    r!   r"   s   @r
   r%   r%   )   s      r   r%   c                   N   a  ] tR t^4t o RtR tR tR tR tR t	R t
R tR	tV tR
# )BrokenRunInfrastructurezi
A test suite that is broken at the level of integration between
L{TestCase.run} and the results object.
c                8    \        W P                  4      ! V4      # )z
Override the normal C{run} behavior to pass the result object
along to the test method.  Each test method needs the result object so
that it can implement its particular kind of brokenness.
)getattr_testMethodNamer	   results   &&r
   runBrokenRunInfrastructure.run:   s     t1126::r   c                8    VP                  \        4       4       R# )z1
Violate the L{TestResult.addSuccess} interface.
N)
addSuccessr%   r7   s   &&r
   test_addSuccess'BrokenRunInfrastructure.test_addSuccessB   s    
 	,.)r   c                     \        R4      h  \         d    \        4       p Mi ; iTP                  \	        4       T4       R# )z/
Violate the L{TestResult.addError} interface.
test_addErrorN)r   BaseExceptionr   addErrorr%   r	   r8   errs   && r
   r@   %BrokenRunInfrastructure.test_addErrorI   s:    	O,, 	*C	 	,    %%c                     \        R4      h  \         d    \        4       p Mi ; iTP                  \	        4       T4       R# )z1
Violate the L{TestResult.addFailure} interface.
test_addFailureN)r   rA   r   
addFailurer%   rC   s   && r
   rH   'BrokenRunInfrastructure.test_addFailureT   s=    	-.. 	*C	 	,.#.rF   c                :    VP                  \        4       R4       R# )z.
Violate the L{TestResult.addSkip} interface.
test_addSkipN)addSkipr%   r7   s   &&r
   rL   $BrokenRunInfrastructure.test_addSkip_   s     	|~~6r   c                     \        R4      h  \         d    \        4       p Mi ; iTP                  \	        4       T4       R# )z9
Violate the L{TestResult.addExpectedFailure} interface.
test_addExpectedFailureN)r   rA   r   addExpectedFailurer%   rC   s   && r
   rP   /BrokenRunInfrastructure.test_addExpectedFailuree   s;    	566 	)C	!!,.#6rF   c                8    VP                  \        4       4       R# )z;
Violate the L{TestResult.addUnexpectedSuccess} interface.
N)addUnexpectedSuccessr%   r7   s   &&r
   test_addUnexpectedSuccess1BrokenRunInfrastructure.test_addUnexpectedSuccesso   s     	##LN3r   r   N)r   r   r   r   r1   r9   r=   r@   rH   rL   rP   rU   r    r!   r"   s   @r
   r3   r3   4   s2     
;*	-	/774 4r   r3   )
r1   r   sysr   twisted.python.failurer   TestCaser   r%   r3   r   r   r
   <module>rZ      sC      *"" 2 ?4h// ?4r   