adding xfail example

--HG--
branch : trunk
This commit is contained in:
holger krekel 2010-05-22 17:22:31 +02:00
parent 545aab85f2
commit 7fc7b4307b
1 changed files with 16 additions and 0 deletions

16
doc/example/xfail_demo.py Normal file
View File

@ -0,0 +1,16 @@
import py
@py.test.mark.xfail
def test_hello():
assert 0
@py.test.mark.xfail(run=False)
def test_hello2():
assert 0
@py.test.mark.xfail("hasattr(os, 'sep')")
def test_hello3():
assert 0
def test_hello5():
py.test.xfail("reason")