diff --git a/runbot_merge/tests/README.txt b/runbot_merge/tests/README.rst similarity index 52% rename from runbot_merge/tests/README.txt rename to runbot_merge/tests/README.rst index 9f531733..0671b9be 100644 --- a/runbot_merge/tests/README.txt +++ b/runbot_merge/tests/README.rst @@ -1,8 +1,9 @@ Execute this test suite using pytest. -The default mode is to run tests locally using mock objects in place of -github, see the docstring of remote.py for additional instructions to run -against github "actual". +The default mode is to run tests locally using a mock github.com. + +See the docstring of remote.py for instructions to run against github "actual" +(including remote-specific options) and the end of this file for a sample. Shared properties running tests, regardless of the github implementation: @@ -17,6 +18,30 @@ Shared properties running tests, regardless of the github implementation: See pytest's documentation for other options, I would recommend ``-rXs``, ``-v`` and ``--showlocals``. -When running "remote" tests as they take a very long time (hours) `-x` +When running "remote" tests as they take a very long time (hours) ``-x`` (aka ``--maxfail=1``) and ``--ff`` (run previously failed first) is also recommended unless e.g. you run the tests overnight. + +``pytest.ini`` sample +--------------------- + +.. code:: ini + + [github] + owner = test-org + token = aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa + + [role_reviewer] + name = Dick Bong + user = loginb + token = bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb + + [role_self_reviewer] + name = Fanny Chmelar + user = loginc + token = cccccccccccccccccccccccccccccccccccccccc + + [role_other] + name = Harry Baals + user = logind + token = dddddddddddddddddddddddddddddddddddddddd diff --git a/runbot_merge/tests/remote.py b/runbot_merge/tests/remote.py index 9e4db608..f0af3288 100644 --- a/runbot_merge/tests/remote.py +++ b/runbot_merge/tests/remote.py @@ -77,7 +77,6 @@ def pytest_addoption(parser): "queries per minute, free is 40, multi-repo batching tests will " "blow through the former); localtunnel has no rate-limiting but " "the servers are way less reliable") - pass @pytest.fixture(scope="session") def config(pytestconfig):