Merge pull request #1225 from pytest-dev/skipping-docs-inconsistency

Fix inconsistency in skipif example
This commit is contained in:
Ronny Pfannschmidt 2015-12-05 20:44:01 +01:00
commit f508a52ca9
1 changed files with 4 additions and 4 deletions

View File

@ -83,8 +83,8 @@ As with all function :ref:`marking <mark>` you can skip test functions at the
`whole class- or module level`_. If your code targets python2.6 or above you
use the skipif decorator (and any other marker) on classes::
@pytest.mark.skipif(sys.platform != 'win32',
reason="requires windows")
@pytest.mark.skipif(sys.platform == 'win32',
reason="does not run on windows")
class TestPosixCalls:
def test_function(self):
@ -97,8 +97,8 @@ If your code targets python2.5 where class-decorators are not available,
you can set the ``pytestmark`` attribute of a class::
class TestPosixCalls:
pytestmark = pytest.mark.skipif(sys.platform != 'win32',
reason="requires Windows")
pytestmark = pytest.mark.skipif(sys.platform == 'win32',
reason="does not run on windows")
def test_function(self):
"will not be setup or run under 'win32' platform"