Merge pull request #5117 from blueyed/cov-terminal
Minor coverage improvements for terminal plugin
This commit is contained in:
commit
3cff5e252d
|
@ -165,15 +165,14 @@ def getreportopt(config):
|
|||
reportchars += "w"
|
||||
elif config.option.disable_warnings and "w" in reportchars:
|
||||
reportchars = reportchars.replace("w", "")
|
||||
if reportchars:
|
||||
for char in reportchars:
|
||||
if char == "a":
|
||||
reportopts = "sxXwEf"
|
||||
elif char == "A":
|
||||
reportopts = "sxXwEfpP"
|
||||
break
|
||||
elif char not in reportopts:
|
||||
reportopts += char
|
||||
for char in reportchars:
|
||||
if char == "a":
|
||||
reportopts = "sxXwEf"
|
||||
elif char == "A":
|
||||
reportopts = "sxXwEfpP"
|
||||
break
|
||||
elif char not in reportopts:
|
||||
reportopts += char
|
||||
return reportopts
|
||||
|
||||
|
||||
|
@ -855,10 +854,8 @@ class TerminalReporter(object):
|
|||
msg = self._getfailureheadline(rep)
|
||||
if rep.when == "collect":
|
||||
msg = "ERROR collecting " + msg
|
||||
elif rep.when == "setup":
|
||||
msg = "ERROR at setup of " + msg
|
||||
elif rep.when == "teardown":
|
||||
msg = "ERROR at teardown of " + msg
|
||||
else:
|
||||
msg = "ERROR at %s of %s" % (rep.when, msg)
|
||||
self.write_sep("_", msg, red=True, bold=True)
|
||||
self._outrep_summary(rep)
|
||||
|
||||
|
|
Loading…
Reference in New Issue