Commits

Jehiah Czebotar  committed 2d3ba68

quieter output for -q

  • Participants
  • Parent commits 67adc73

Comments (0)

Files changed (1)

File _pytest/terminal.py

     def report_collect(self, final=False):
         errors = len(self.stats.get('error', []))
         skipped = len(self.stats.get('skipped', []))
+
         if final:
             line = "collected "
         else:
             line += " / %d errors" % errors
         if skipped:
             line += " / %d skipped" % skipped
+        if not self.showheader and not errors:
+            return
         if self.hasmarkup:
             if final:
                 line += " \n"
         if self.verbosity >= 0:
             self.write_sep("=", msg, bold=True)
         else:
-            self.write_line(msg, bold=True)
+            if self.verbosity < 0:
+                self.write(msg)
+            else:
+                self.write_line(msg, bold=True)
 
     def summary_deselected(self):
         if 'deselected' in self.stats: