%PDF- %PDF-
Direktori : /usr/local/lib/python3.8/unittest/__pycache__/ |
Current File : //usr/local/lib/python3.8/unittest/__pycache__/runner.cpython-38.pyc |
U q©ßaW ã @ sn d Z ddlZddlZddlZddlmZ ddlmZ dZG dd„ de ƒZ G d d „ d ejƒZG dd„ de ƒZ dS ) z Running testsé Né )Úresult)ÚregisterResultTc @ s* e Zd ZdZdd„ Zdd„ Zd dd„ZdS ) Ú_WritelnDecoratorz@Used to decorate file-like objects with a handy 'writeln' methodc C s || _ d S ©N)Ústream)Úselfr © r ú+/usr/local/lib/python3.8/unittest/runner.pyÚ__init__ s z_WritelnDecorator.__init__c C s |dkrt |ƒ‚t| j|ƒS )N)r Ú__getstate__)ÚAttributeErrorÚgetattrr )r Úattrr r r Ú__getattr__ s z_WritelnDecorator.__getattr__Nc C s |r| |¡ | d¡ d S ©NÚ )Úwrite)r Úargr r r Úwriteln s z_WritelnDecorator.writeln)N)Ú__name__Ú __module__Ú__qualname__Ú__doc__r r r r r r r r s r c s” e Zd ZdZdZdZ‡ fdd„Zdd„ Z‡ fdd „Z‡ fd d„Z ‡ fdd „Z ‡ fdd„Z‡ fdd„Z‡ fdd„Z ‡ fdd„Zdd„ Zdd„ Z‡ ZS )ÚTextTestResultzhA test result class that can print formatted text results to a stream. Used by TextTestRunner. zF======================================================================zF----------------------------------------------------------------------c s8 t t| ƒ |||¡ || _|dk| _|dk| _|| _d S )Nr )Úsuperr r r ÚshowAllÚdotsÚdescriptions)r r r Ú verbosity©Ú __class__r r r % s zTextTestResult.__init__c C s0 | ¡ }| jr$|r$d t|ƒ|f¡S t|ƒS d S r )ZshortDescriptionr ÚjoinÚstr)r ÚtestZdoc_first_liner r r ÚgetDescription, s zTextTestResult.getDescriptionc sB t t| ƒ |¡ | jr>| j | |¡¡ | j d¡ | j ¡ d S )Nz ... )r r Ú startTestr r r r% Úflush©r r$ r r r r&