Why Gemfury? Push, build, and install  RubyGems npm packages Python packages Maven artifacts PHP packages Go Modules Debian packages RPM packages NuGet packages

Repository URL to install this package:

Details    
Size: Mime:
B

b½nŸýCUã@sVdZddlZddlZddlmZddlmZmZddlm	Z	eeƒZGdd„dƒZ
dS)z'Source file annotation for coverage.py.éN)Ú
flat_rootname)Ú
ensure_dirÚisolate_module)Úget_analysis_to_reportc@s>eZdZdZdd„Ze d¡Ze d¡Zddd„Z	d	d
„Z
dS)ÚAnnotateReporteraGenerate annotated source files showing line coverage.

    This reporter creates annotated copies of the measured source files. Each
    .py file is copied as a .py,cover file, with a left-hand margin annotating
    each line::

        > def h(x):
        -     if 0:   #pragma: no cover
        -         pass
        >     if x == 1:
        !         a = 1
        >     else:
        >         a = 2

        > h(2)

    Executed lines use '>', lines not executed use '!', lines excluded from
    consideration use '-'.

    cCs||_|jj|_d|_dS)N)ÚcoverageÚconfigÚ	directory)Úselfr©rú/build/wlanpi-profiler-7IIg1Q/wlanpi-profiler-1.0.11/debian/wlanpi-profiler/opt/wlanpi-profiler/lib/python3.7/site-packages/coverage/annotate.pyÚ__init__&s
zAnnotateReporter.__init__z\s*(#|$)z\s*else\s*:\s*(#|$)NcCs:||_|j ¡x$t|j|ƒD]\}}| ||¡qWdS)zIRun the report.

        See `coverage.report()` for arguments.

        N)r	rÚget_datarÚ
annotate_file)r
Zmorfsr	ÚfrÚanalysisrrrÚreport.s
zAnnotateReporter.reportc	Csút|jƒ}t|jƒ}t|jƒ}|jrjt|jƒtj |jt	| 
¡ƒ¡}| d¡r`|dd…d}|d7}n
|jd}t
|dddl}d	}}	d
}
| ¡}xNt| d
¡ddD]6\}}
x$|t|ƒkrÞ|||krÞ|d7}q¼Wx(|	t|ƒkr||	|kr|	d7}	qâW|t|ƒkr@|||kr@|	t|ƒkp>||	|k}
|j |
¡rZ| d
¡n„|j |
¡r¬|	t|ƒkr‚| d¡n(||||	kr | d¡n
| d¡n2||krÂ| d¡n|
rÔ| d¡n
| d¡| |
¡q°WWdQRXdS)z]Annotate a single file.

        `fr` is the FileReporter for the file to annotate.

        Z_pyNéýÿÿÿz.pyz,coverÚwzutf-8)ÚencodingrTé)Ústartz  z> z! z- )ÚsortedÚ
statementsÚmissingÚexcludedr	rÚosÚpathÚjoinrZrelative_filenameÚendswithÚfilenameÚopenÚsourceÚ	enumerateÚ
splitlinesÚlenÚblank_reÚmatchÚwriteÚelse_re)r
rrrrrÚ	dest_fileÚdestÚiÚjZcoveredr"ÚlinenoÚlinerrrr9sF






 

zAnnotateReporter.annotate_file)N)Ú__name__Ú
__module__Ú__qualname__Ú__doc__r
ÚreÚcompiler&r)rrrrrrrs


r)r3rr4Zcoverage.filesrZ
coverage.miscrrZcoverage.reportrrrrrrÚ<module>s