pytest: silence pytest warnings about unregistered 'slow_test' marker

We've been getting a bunch of 'warnings' about an unknown mark. This
silences the warning, by registering the mark as expected.

=========================================================== warnings summary ===========================================================
tests/test_closing.py:152
  /home/niftynei/dev/lightning/tests/test_closing.py:152: PytestUnknownMarkWarning: Unknown pytest.mark.slow_test - is this a typo?  You can register custom marks to avoid this warning - for details, see https://docs.pytest.org/en/latest/mark.html
    @pytest.mark.slow_test

tests/test_closing.py:214
  /home/niftynei/dev/lightning/tests/test_closing.py:214: PytestUnknownMarkWarning: Unknown pytest.mark.slow_test - is this a typo?  You can register custom marks to avoid this warning - for details, see https://docs.pytest.org/en/latest/mark.html
    @pytest.mark.slow_test

tests/test_closing.py:704
This commit is contained in:
niftynei 2020-11-10 13:44:04 -06:00 committed by neil saitug
parent 9f5f9e15d0
commit 72dc97c0c1

View File

@ -16,3 +16,8 @@ def pytest_runtest_makereport(item, call):
# be "setup", "call", "teardown"
setattr(item, "rep_" + rep.when, rep)
def pytest_configure(config):
config.addinivalue_line("markers",
"slow_test: slow tests aren't run under Valgrind")