diff options
author | Ned Batchelder <ned@nedbatchelder.com> | 2013-09-04 09:25:13 -0400 |
---|---|---|
committer | Ned Batchelder <ned@nedbatchelder.com> | 2013-09-04 09:25:13 -0400 |
commit | f94f6a874e8466ecd825b796419606225a770668 (patch) | |
tree | 5db8ed191a23323b96b1bf61ab04d4aebebed28a /coverage/cmdline.py | |
parent | 1ffbdc3328de90783d0ba962838b3f7924adf77c (diff) | |
download | python-coveragepy-f94f6a874e8466ecd825b796419606225a770668.tar.gz |
New flag for run: --debug, can trace why files aren't being traced.
Diffstat (limited to 'coverage/cmdline.py')
-rw-r--r-- | coverage/cmdline.py | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/coverage/cmdline.py b/coverage/cmdline.py index ac80310..51d8043 100644 --- a/coverage/cmdline.py +++ b/coverage/cmdline.py @@ -19,6 +19,10 @@ class Opts(object): '', '--branch', action='store_true', help="Measure branch coverage in addition to statement coverage." ) + debug = optparse.make_option( + '', '--debug', action='store', metavar="OPTS", + help="Debug options, separated by commas" + ) directory = optparse.make_option( '-d', '--directory', action='store', metavar="DIR", help="Write the output files to DIR." @@ -117,6 +121,7 @@ class CoverageOptionParser(optparse.OptionParser, object): self.set_defaults( actions=[], branch=None, + debug=None, directory=None, fail_under=None, help=None, @@ -310,6 +315,7 @@ CMDS = { [ Opts.append, Opts.branch, + Opts.debug, Opts.pylib, Opts.parallel_mode, Opts.module, @@ -404,6 +410,7 @@ class CoverageScript(object): source = unshell_list(options.source) omit = unshell_list(options.omit) include = unshell_list(options.include) + debug = unshell_list(options.debug) # Do something. self.coverage = self.covpkg.coverage( @@ -415,6 +422,7 @@ class CoverageScript(object): source = source, omit = omit, include = include, + debug = debug, ) if 'debug' in options.actions: |