]> git.pld-linux.org Git - packages/python-pytest-benchmark.git/blob - python-pytest-benchmark-capture.patch
- initial, tests not run for now
[packages/python-pytest-benchmark.git] / python-pytest-benchmark-capture.patch
1 Adjust for recent pytest
2 --- pytest-benchmark-3.1.1/src/pytest_benchmark/logger.py.orig  2017-07-26 13:48:12.000000000 +0200
3 +++ pytest-benchmark-3.1.1/src/pytest_benchmark/logger.py       2018-08-03 07:41:12.218113772 +0200
4 @@ -24,14 +24,14 @@
5      def warn(self, code, text, warner=None, suspend=False, fslocation=None):
6          if self.verbose:
7              if suspend and self.capman:
8 -                self.capman.suspendcapture(in_=True)
9 +                self.capman.suspend_global_capture(in_=True)
10              self.term.line("")
11              self.term.sep("-", red=True, bold=True)
12              self.term.write(" WARNING: ", red=True, bold=True)
13              self.term.line(text, red=True)
14              self.term.sep("-", red=True, bold=True)
15              if suspend and self.capman:
16 -                self.capman.resumecapture()
17 +                self.capman.resume_global_capture()
18          if warner is None:
19              warner = self.pytest_warn
20          if fslocation and self.pytest_warn_has_fslocation:
21 @@ -55,7 +55,7 @@
22      def debug(self, text, **kwargs):
23          if self.verbose:
24              if self.capman:
25 -                self.capman.suspendcapture(in_=True)
26 +                self.capman.suspend_global_capture(in_=True)
27              self.info(text, **kwargs)
28              if self.capman:
29 -                self.capman.resumecapture()
30 +                self.capman.resume_global_capture()
This page took 0.078696 seconds and 3 git commands to generate.