diff --git a/core/src/zeit/connector/testing.py b/core/src/zeit/connector/testing.py index f9d3e34022..8978ccf5b5 100644 --- a/core/src/zeit/connector/testing.py +++ b/core/src/zeit/connector/testing.py @@ -9,7 +9,6 @@ from sqlalchemy.exc import OperationalError import docker import plone.testing -import pytest import requests import sqlalchemy import transaction @@ -320,7 +319,6 @@ def get_resource(self, name, body=b'', properties=None, contentType='text/plain' ) -@pytest.mark.slow() class ConnectorTest(TestCase): layer = REAL_CONNECTOR_LAYER level = 2 @@ -343,14 +341,6 @@ def FunctionalDocFileSuite(*paths, **kw): return zeit.cms.testing.FunctionalDocFileSuite(*paths, **kw) -def mark_doctest_suite(suite, mark): - # Imitate pytest magic, see _pytest.python.transfer_markers - for test in suite: - func = test.runTest.__func__ - mark(func) - test.runTest = func.__get__(test) - - def print_tree(connector, base): """Helper to print a tree.""" print('\n'.join(list_tree(connector, base))) diff --git a/core/src/zeit/connector/tests/test_doctest.py b/core/src/zeit/connector/tests/test_doctest.py index d9754aaeaf..d42e76ef03 100755 --- a/core/src/zeit/connector/tests/test_doctest.py +++ b/core/src/zeit/connector/tests/test_doctest.py @@ -1,7 +1,5 @@ import unittest -import pytest - import zeit.cms.testing import zeit.connector.connector import zeit.connector.testing @@ -23,7 +21,6 @@ def test_suite(): 'invalidation-events.txt', layer=zeit.connector.testing.ZOPE_CONNECTOR_LAYER, ) - zeit.connector.testing.mark_doctest_suite(functional, pytest.mark.slow) suite.addTest(functional) suite.addTest(zeit.cms.testing.DocFileSuite('search.txt', package='zeit.connector')) diff --git a/core/src/zeit/connector/tests/test_doctest2.py b/core/src/zeit/connector/tests/test_doctest2.py index 6d3200a05e..d7d96bbaff 100644 --- a/core/src/zeit/connector/tests/test_doctest2.py +++ b/core/src/zeit/connector/tests/test_doctest2.py @@ -1,5 +1,3 @@ -import pytest - import zeit.cms.testing import zeit.connector.connector import zeit.connector.testing @@ -8,7 +6,7 @@ def test_suite(): # Need to put this into a separate file, otherwise gocept.pytestlayers # does not tear down other layers before running this. - suite = zeit.connector.testing.FunctionalDocFileSuite( + return zeit.connector.testing.FunctionalDocFileSuite( 'locking.txt', 'resource.txt', 'search-ft.txt', @@ -17,5 +15,3 @@ def test_suite(): # 'stressing.txt', layer=zeit.connector.testing.REAL_CONNECTOR_LAYER, ) - zeit.connector.testing.mark_doctest_suite(suite, pytest.mark.slow) - return suite diff --git a/core/src/zeit/pytest.py b/core/src/zeit/pytest.py index 0806d3ca87..867a1be0c6 100644 --- a/core/src/zeit/pytest.py +++ b/core/src/zeit/pytest.py @@ -18,9 +18,4 @@ def pytest_configure(config): config.addinivalue_line( 'markers', 'integration: Thirdparty integration tests are not run by default.' ) - config.addinivalue_line( - 'markers', - 'slow: This is a non-unit test and thus is not run by ' - 'default. Use ``-m slow`` to run these, or ``-m 1`` to run all tests.', - ) config.addinivalue_line('markers', 'selenium: Selenium tests are not run by default.')