summaryrefslogtreecommitdiff
path: root/tests/test_debug.py
diff options
context:
space:
mode:
authorNed Batchelder <ned@nedbatchelder.com>2021-01-31 10:10:47 -0500
committerNed Batchelder <ned@nedbatchelder.com>2021-01-31 10:10:47 -0500
commitd02be78c3a0ee3022be56c623bb9bdcad1e9acd4 (patch)
tree1e74153bb4741f6a9e2f1e1f55d2b9960a490bb3 /tests/test_debug.py
parenta035bde3320a501720ae722dc6b54fe7ff5c8647 (diff)
downloadpython-coveragepy-git-d02be78c3a0ee3022be56c623bb9bdcad1e9acd4.tar.gz
style: fix long lines and avoid backslashesnedbat/unittest2pytest
Diffstat (limited to 'tests/test_debug.py')
-rw-r--r--tests/test_debug.py10
1 files changed, 4 insertions, 6 deletions
diff --git a/tests/test_debug.py b/tests/test_debug.py
index 42d7945e..16669407 100644
--- a/tests/test_debug.py
+++ b/tests/test_debug.py
@@ -176,9 +176,8 @@ class DebugTraceTest(CoverageTest):
""".split()
for label in labels:
label_pat = r"^\s*%s: " % label
- assert len(re_lines(out_lines, label_pat).splitlines()) == \
- 1, \
- "Incorrect lines for %r" % label
+ msg = "Incorrect lines for %r" % label
+ assert 1 == len(re_lines(out_lines, label_pat).splitlines()), msg
def test_debug_sys(self):
out_lines = self.f1_debug_output(["sys"])
@@ -190,9 +189,8 @@ class DebugTraceTest(CoverageTest):
""".split()
for label in labels:
label_pat = r"^\s*%s: " % label
- assert len(re_lines(out_lines, label_pat).splitlines()) == \
- 1, \
- "Incorrect lines for %r" % label
+ msg = "Incorrect lines for %r" % label
+ assert 1 == len(re_lines(out_lines, label_pat).splitlines()), msg
def test_debug_sys_ctracer(self):
out_lines = self.f1_debug_output(["sys"])