summaryrefslogtreecommitdiff
path: root/coverage/control.py
diff options
context:
space:
mode:
authorNed Batchelder <ned@nedbatchelder.com>2018-08-30 08:55:49 -0400
committerNed Batchelder <ned@nedbatchelder.com>2018-08-30 16:46:17 -0400
commitb764393571dbb84996f26b7f52cb02599b44b5a9 (patch)
tree781718a6a26277991b8a3fb211e3882a22fca494 /coverage/control.py
parente82f5d884e1f08275f0343f280ed3500b4b6d47a (diff)
downloadpython-coveragepy-git-b764393571dbb84996f26b7f52cb02599b44b5a9.tar.gz
Show the contents of the config file
Diffstat (limited to 'coverage/control.py')
-rw-r--r--coverage/control.py6
1 files changed, 6 insertions, 0 deletions
diff --git a/coverage/control.py b/coverage/control.py
index 1e23dcd5..580fc9da 100644
--- a/coverage/control.py
+++ b/coverage/control.py
@@ -223,6 +223,7 @@ class Coverage(object):
with self._debug.without_callers():
if self._debug.should('config'):
config_info = sorted(self.config.__dict__.items())
+ config_info = [(k, v) for k, v in config_info if not k.startswith('_')]
write_formatted_info(self._debug, "config", config_info)
wrote_any = True
@@ -840,6 +841,11 @@ class Coverage(object):
('configs_attempted', self.config.attempted_config_files),
('configs_read', self.config.config_files_read),
('config_file', self.config.config_file),
+ ('config_contents',
+ repr(self.config._config_contents)
+ if self.config._config_contents
+ else '-none-'
+ ),
('data_file', self._data.filename if self._data else "-none-"),
('python', sys.version.replace('\n', '')),
('platform', platform.platform()),