summaryrefslogtreecommitdiff
path: root/coverage/debug.py
diff options
context:
space:
mode:
authorNed Batchelder <ned@nedbatchelder.com>2018-10-13 10:17:10 -0400
committerNed Batchelder <ned@nedbatchelder.com>2018-10-13 10:17:10 -0400
commit3569f921992e10036281d469f22cf4a2e06a6c45 (patch)
tree1cf1cda352dbf3df1935f8c2156d09133abc5531 /coverage/debug.py
parent8f41c9714de5a75e031b4ea8a744f9d7860e8c05 (diff)
downloadpython-coveragepy-git-3569f921992e10036281d469f22cf4a2e06a6c45.tar.gz
Fewer conditionals for debug output
Diffstat (limited to 'coverage/debug.py')
-rw-r--r--coverage/debug.py6
1 files changed, 6 insertions, 0 deletions
diff --git a/coverage/debug.py b/coverage/debug.py
index ce22d725..2c5c6aaf 100644
--- a/coverage/debug.py
+++ b/coverage/debug.py
@@ -91,6 +91,12 @@ class DebugControlString(DebugControl):
return self.raw_output.getvalue()
+class NoDebugging(object):
+ """A replacement for DebugControl that will never try to do anything."""
+ def should(self, option):
+ return False
+
+
def info_header(label):
"""Make a nice header string."""
return "--{0:-<60s}".format(" "+label+" ")