From bb6f3ebd3111fb40ce678ad95fd940b580c97b77 Mon Sep 17 00:00:00 2001 From: holger krekel Date: Tue, 16 Apr 2013 09:04:05 +0200 Subject: [PATCH] slightly improve -k help string cosmetic change to test_nose.py --- _pytest/mark.py | 4 ++-- testing/test_nose.py | 6 ++++-- 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/_pytest/mark.py b/_pytest/mark.py index 34c640ffe..7b6b2d00d 100644 --- a/_pytest/mark.py +++ b/_pytest/mark.py @@ -7,8 +7,8 @@ def pytest_namespace(): def pytest_addoption(parser): group = parser.getgroup("general") group._addoption('-k', - action="store", dest="keyword", default='', metavar="KEYWORDEXPR", - help="only run tests which match the given expression. " + action="store", dest="keyword", default='', metavar="EXPRESSION", + help="only run tests which match the given substring expression. " "An expression is a python evaluatable expression " "where all names are substring-matched against test names " "and keywords. Example: -k 'test_method or test_other' " diff --git a/testing/test_nose.py b/testing/test_nose.py index cdebca8dd..3ecfa9c07 100644 --- a/testing/test_nose.py +++ b/testing/test_nose.py @@ -304,8 +304,9 @@ def test_apiwrapper_problem_issue260(testdir): result = testdir.runpytest() result.stdout.fnmatch_lines("*1 passed*") +@pytest.mark.skipif("sys.version_info < (2,6)") def test_setup_teardown_linking_issue265(testdir): - # we accidnetially didnt integrate nose setupstate with normal setupstate + # we accidentally didnt integrate nose setupstate with normal setupstate # this test ensures that won't happen again testdir.makepyfile(''' import pytest @@ -314,7 +315,8 @@ def test_setup_teardown_linking_issue265(testdir): def test_nothing(self): """Tests the API of the implementation (for generic and specialized).""" - @pytest.mark.skipif("True", reason="Skip tests to check if teardown is skipped as well.") + @pytest.mark.skipif("True", reason= + "Skip tests to check if teardown is skipped as well.") class TestSkipTeardown(TestGeneric): def setup(self):