Submit
Path:
~
/
/
proc
/
thread-self
/
root
/
opt
/
alt
/
python35
/
lib
/
python3.5
/
site-packages
/
nose
/
plugins
/
__pycache__
/
File Content:
prof.cpython-35.opt-1.pyc
�fP� � @ s� d Z y d d l Z d d l m Z Wn e k rF d \ Z Z Yn Xd d l Z d d l Z d d l Z d d l Z d d l m Z d d l m Z e j d � Z Gd d � d e � Z d S) a/ This plugin will run tests using the hotshot profiler, which is part of the standard library. To turn it on, use the ``--with-profile`` option or set the NOSE_WITH_PROFILE environment variable. Profiler output can be controlled with the ``--profile-sort`` and ``--profile-restrict`` options, and the profiler output file may be changed with ``--profile-stats-file``. See the `hotshot documentation`_ in the standard library documentation for more details on the various output options. .. _hotshot documentation: http://docs.python.org/library/hotshot.html � N)�stats)�Plugin)�tolistznose.pluginsc @ s� e Z d Z d Z d Z d Z d d � Z d d � Z e e � Z d d � Z d d � Z d d � Z d d � Z d d � Z d d � Z d S)�ProfilezC Use this plugin to run tests using the hotshot profiler. NFc C s� | j � s d St j | | | � | j d d d d d d | j d d � d d d d �| j d d d d d d d d | j d � d d �| j d d d d d d d d | j d � d d �d S)z&Register commandline options. Nz--profile-sort�actionZstore�dest�profile_sort�defaultZNOSE_PROFILE_SORTZ cumulative�metavarZSORT�helpz"Set sort order for profiler outputz--profile-stats-file�profile_stats_file�FILEZNOSE_PROFILE_STATS_FILEz;Profiler stats file; default is a new temp file on each runz--profile-restrict�append�profile_restrictZRESTRICTZNOSE_PROFILE_RESTRICTz?Restrict profiler output. See help for pstats.Stats for details)� availabler �optionsZ add_option�get)�self�parser�env� r �/prof.pyr ! s"