From 994fb00badbc523278342d9c6903aa4dff96ebd1 Mon Sep 17 00:00:00 2001 From: Ned Batchelder Date: Wed, 2 Oct 2019 21:08:04 -0400 Subject: [PATCH] Update for coverage 5.0a8 --- tests/test_pytest_cov.py | 4 ++-- tox.ini | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/tests/test_pytest_cov.py b/tests/test_pytest_cov.py index a09e0725..adc28d54 100644 --- a/tests/test_pytest_cov.py +++ b/tests/test_pytest_cov.py @@ -2005,8 +2005,8 @@ def test_contexts(testdir, opts): for context, label in EXPECTED_CONTEXTS.items(): if context == '': continue - context_pattern = re.sub(r"[\[\|]", r"[\g<0>]", context) - actual = data.lines(test_context_path, contexts=[context_pattern]) + data.set_query_context(context) + actual = data.lines(test_context_path) assert line_data[label] == actual, "Wrong lines for context {!r}".format(context) diff --git a/tox.ini b/tox.ini index 2d993db0..fd5a9f5c 100644 --- a/tox.ini +++ b/tox.ini @@ -30,7 +30,7 @@ setenv = xdist29: _DEP_PYTESTXDIST=pytest-xdist==1.29.0 coverage45: _DEP_COVERAGE=coverage==4.5.4 - coverage50: _DEP_COVERAGE=coverage==5.0a7 + coverage50: _DEP_COVERAGE=coverage==5.0a8 passenv = *