diff options
author | Bruno Oliveira <nicoddemus@gmail.com> | 2019-10-05 14:18:51 -0300 |
---|---|---|
committer | Bruno Oliveira <nicoddemus@gmail.com> | 2019-10-06 18:05:24 -0300 |
commit | 47c2091ecd2f341e10f38f1d505c21fb3323c140 (patch) | |
tree | 30bfbea20a87c09ca11682d0facfd7e4db86cef6 /testing/code | |
parent | 0c18e244334d1c04fa2a7942fe5e2eb179ba6915 (diff) | |
download | pytest-47c2091ecd2f341e10f38f1d505c21fb3323c140.tar.gz |
Use new no-match functions to replace previous idiom
Diffstat (limited to 'testing/code')
-rw-r--r-- | testing/code/test_excinfo.py | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/testing/code/test_excinfo.py b/testing/code/test_excinfo.py index 5673b811b..e2f06a0a2 100644 --- a/testing/code/test_excinfo.py +++ b/testing/code/test_excinfo.py @@ -399,7 +399,7 @@ def test_match_raises_error(testdir): result = testdir.runpytest() assert result.ret != 0 result.stdout.fnmatch_lines(["*AssertionError*Pattern*[123]*not found*"]) - assert "__tracebackhide__ = True" not in result.stdout.str() + result.stdout.no_fnmatch_line("*__tracebackhide__ = True*") result = testdir.runpytest("--fulltrace") assert result.ret != 0 @@ -1343,7 +1343,8 @@ def test_cwd_deleted(testdir): ) result = testdir.runpytest() result.stdout.fnmatch_lines(["* 1 failed in *"]) - assert "INTERNALERROR" not in result.stdout.str() + result.stderr.str() + result.stdout.no_fnmatch_line("*INTERNALERROR*") + result.stderr.no_fnmatch_line("*INTERNALERROR*") @pytest.mark.usefixtures("limited_recursion_depth") |