Use a better xfail reason

This commit is contained in:
Raphael Pierzina 2016-08-17 22:31:56 +01:00
parent bb3d6d87b6
commit d1f2f779ee
1 changed files with 2 additions and 2 deletions

View File

@ -145,7 +145,7 @@ class TestXFail:
def test_xfail_xpassed(self, testdir):
item = testdir.getitem("""
import pytest
@pytest.mark.xfail(reason="nope")
@pytest.mark.xfail(reason="this is an xfail")
def test_func():
assert 1
""")
@ -153,7 +153,7 @@ class TestXFail:
assert len(reports) == 3
callreport = reports[1]
assert callreport.passed
assert callreport.wasxfail == "nope"
assert callreport.wasxfail == "this is an xfail"
def test_xfail_xpassed_strict(self, testdir):
item = testdir.getitem("""