Repository URL to install this package:
Version:
1.0.8-1 ▾
|
wlanpi-profiler
/
opt
/
wlanpi-profiler
/
lib
/
python3.7
/
site-packages
/
coverage
/
__pycache__
/
control.cpython-37.pyc
|
---|
B °։Z"ÜAã @ s. d Z ddlZddlZddlZddlZddlZddlZddlZddlZddl m Z ddlmZ ddl mZmZ ddlmZmZ ddlmZ ddlmZmZ dd lmZmZ dd lmZmZmZ ddlm Z ddl!m"Z"m#Z#m$Z$m%Z% dd l&m'Z' ddl(m)Z) ddl*m+Z+ ddl,m-Z-m.Z.m/Z/ ddl,m0Z0m1Z1m2Z2 ddl3m4Z4 ddl5m6Z6 ddl7m8Z8 ddl9m:Z: ddl;m<Z<m=Z= ddl>m?Z? ddl@mAZA yddlBmCZC W n eDk r® dZCY nX e2eZejEdd ZFe0dZGG dd deHZIeJejK Ldd¡rdd lmMZMmNZN eMeNd!d"d#gd$eIZId%d& ZOd'd( ZPdS ))z#Core control stuff for coverage.py.é N)Úenv)ÚAnnotateReporter)Ústring_classÚiitems)Ú CollectorÚCTracer)Úread_coverage_config)Ú"should_start_context_test_functionÚcombine_context_switchers)ÚCoverageDataÚcombine_parallel_data)ÚDebugControlÚshort_stackÚwrite_formatted_info)Údisposition_debug_msg)ÚPathAliasesÚabs_fileÚrelative_filenameÚset_relative_directory)ÚHtmlReporter)ÚInOrOut)ÚJsonReporter)ÚCoverageExceptionÚbool_or_noneÚ join_regex)ÚDefaultValueÚensure_dir_for_fileÚisolate_module)ÚFileReporter)ÚPlugins)ÚPythonFileReporter)Ú render_report)ÚAnalysisÚNumbers)ÚSummaryReporter)ÚXmlReporter)Úpatch_multiprocessingc k s8 | j }| j ¡ | _ z| j jf | dV W d|| _ X dS )zÇTemporarily tweak the configuration of `cov`. The arguments are applied to `cov.config` with the `from_args` method. At the end of the with-statement, the old configuration is restored. N)ÚconfigÚcopyZ from_args)ÚcovÚkwargsZoriginal_config© r+ ú/build/wlanpi-profiler-MIf3Xw/wlanpi-profiler-1.0.8/debian/wlanpi-profiler/opt/wlanpi-profiler/lib/python3.7/site-packages/coverage/control.pyÚoverride_config. s r- ÚMISSINGc @ s~ e Zd ZdZg Zedd ZeddddddddddddddfddZd d Z dd Z d d Zdd Zdd Z dRddZdd Zdd Zdd Zdd Zdd Zdd Zd!d" Zd#d$ Zd%d& Zd'd( ZdSd*d+ZdTd,d-Zd.d/ Zd0d1 ZdUd2d3Zd4d5 ZdVd6d7Zd8d9 Z d:d; Z!d<d= Z"d>d? Z#d@dA Z$dBdC Z%dWdDdEZ&dXdFdGZ'dYdHdIZ(dZdJdKZ)d[dLdMZ*d\dNdOZ+dPdQ Z,dS )]ÚCoverageaÁ Programmatic access to coverage.py. To use:: from coverage import Coverage cov = Coverage() cov.start() #.. call your code .. cov.stop() cov.html_report(directory='covhtml') Note: in keeping with Python custom, names starting with underscore are not part of the public API. They might stop working at any point. Please limit yourself to documented methods to avoid problems. c C s | j r| j d S dS dS )zGet the latest started `Coverage` instance, if any. Returns: a `Coverage` instance, or None. .. versionadded:: 5.0 éÿÿÿÿN)Ú _instances)Úclsr+ r+ r, ÚcurrentV s zCoverage.currentNFTc C sÖ |dk| _ |tkrd}t|||||t||| | ||| || |d| _d| _| | _| _|| _d| _ d| _ || _d| _g | _ d | _| _d| _d| _d | _| _d| _d| _d| _d| _d| _d| _d| _tjsÒt dS )aL Many of these arguments duplicate and override values that can be provided in a configuration file. Parameters that are missing here will use values from the config file. `data_file` is the base name of the data file to use. The config value defaults to ".coverage". None can be provided to prevent writing a data file. `data_suffix` is appended (with a dot) to `data_file` to create the final file name. If `data_suffix` is simply True, then a suffix is created with the machine and process identity included. `cover_pylib` is a boolean determining whether Python code installed with the Python interpreter is measured. This includes the Python standard library and any packages installed with the interpreter. If `auto_data` is true, then any existing data file will be read when coverage measurement starts, and data will be saved automatically when measurement stops. If `timid` is true, then a slower and simpler trace function will be used. This is important for some environments where manipulation of tracing functions breaks the faster trace function. If `branch` is true, then branch coverage will be measured in addition to the usual statement coverage. `config_file` determines what configuration file to read: * If it is ".coveragerc", it is interpreted as if it were True, for backward compatibility. * If it is a string, it is the name of the file to read. If the file can't be read, it is an error. * If it is True, then a few standard files names are tried (".coveragerc", "setup.cfg", "tox.ini"). It is not an error for these files to not be found. * If it is False, then no configuration file is read. `source` is a list of file paths or package names. Only code located in the trees indicated by the file paths or package names will be measured. `source_pkgs` is a list of package names. It works the same as `source`, but can be used to name packages where the name can also be interpreted as a file path. `include` and `omit` are lists of file name patterns. Files that match `include` will be measured, files that match `omit` will not. Each will also accept a single string argument. `debug` is a list of strings indicating what debugging information is desired. `concurrency` is a string indicating the concurrency library being used in the measured code. Without this, coverage.py will get incorrect results if these libraries are in use. Valid strings are "greenlet", "eventlet", "gevent", "multiprocessing", or "thread" (the default). This can also be a list of these strings. If `check_preimported` is true, then when coverage is started, the already-imported files will be checked to see if they should be measured by coverage. Importing measured files before coverage is started can mean that code is missed. `context` is a string to use as the :ref:`static context <static_contexts>` label for collected data. .. versionadded:: 4.0 The `concurrency` parameter. .. versionadded:: 4.2 The `concurrency` parameter can now be a list of strings. .. versionadded:: 5.0 The `check_preimported` and `context` parameters. .. versionadded:: 5.3 The `source_pkgs` parameter. N)Úconfig_fileÚ data_fileÚcover_pylibÚtimidÚbranchÚparallelÚsourceÚsource_pkgsZrun_omitZrun_includeÚdebugÚreport_omitÚreport_includeÚconcurrencyÚcontextTF)Ú_no_diskÚ_DEFAULT_DATAFILEr r r' Ú_debug_fileÚ _auto_loadÚ _auto_saveÚ_data_suffix_specifiedÚ _warn_no_dataÚ_warn_unimported_sourceÚ_warn_preimported_sourceÚ_no_warn_slugsÚ _warningsÚ_dataÚ _collectorÚ_pluginsÚ_inoroutZ_data_suffixZ_run_suffixÚ_exclude_reÚ_debugÚ_file_mapperÚ_initedÚ_inited_for_startÚ_startedÚ_should_write_debugr ZMETACOVÚ _prevent_sub_process_measurement)Úselfr5 Zdata_suffixr6 Z auto_datar7 r8 r4 r: r; ÚomitÚincluder<