fix linting issues

This commit is contained in:
Ronny Pfannschmidt 2017-07-28 18:27:59 +02:00
parent 06a49338b2
commit be401bc2f8
5 changed files with 7 additions and 12 deletions

View File

@ -52,6 +52,7 @@ class Exit(KeyboardInterrupt):
# exposed helper methods
def exit(msg):
""" exit testing process as if KeyboardInterrupt was triggered. """
__tracebackhide__ = True
@ -87,7 +88,6 @@ def fail(msg="", pytrace=True):
fail.Exception = Failed
class XFailed(fail.Exception):
""" raised from an explicit call to pytest.xfail() """
@ -101,7 +101,6 @@ def xfail(reason=""):
xfail.Exception = XFailed
def importorskip(modname, minversion=None):
""" return imported module if it has at least "minversion" as its
__version__ attribute. If no minversion is specified the a skip

View File

@ -11,6 +11,7 @@ import warnings
from _pytest.fixtures import yield_fixture
from _pytest.outcomes import fail
@yield_fixture
def recwarn():
"""Return a WarningsRecorder instance that provides these methods:

View File

@ -13,6 +13,7 @@ from _pytest.outcomes import skip, Skipped, TEST_OUTCOME
#
# pytest plugin hooks
def pytest_addoption(parser):
group = parser.getgroup("terminal reporting", "reporting", after="general")
group.addoption('--durations',
@ -505,7 +506,3 @@ def collect_one_node(collector):
if call and check_interactive_exception(call, rep):
ihook.pytest_exception_interact(node=collector, call=call, report=rep)
return rep

View File

@ -60,7 +60,6 @@ def pytest_configure(config):
)
class MarkEvaluator:
def __init__(self, item, name):
self.item = item

View File

@ -461,7 +461,6 @@ def test_outcomeexception_passes_except_Exception():
pass
def test_pytest_exit():
try:
pytest.exit("hello")