From 2c0ce0964d9cdd6b934bfdedda7e2e3746ef04c0 Mon Sep 17 00:00:00 2001 From: Yannick PEROUX Date: Fri, 13 Jan 2023 11:25:23 +0100 Subject: [PATCH] Add a test for '-p ' arg --- testing/test_config.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/testing/test_config.py b/testing/test_config.py index f5b6d7f98..2b6ebb53e 100644 --- a/testing/test_config.py +++ b/testing/test_config.py @@ -1809,6 +1809,10 @@ def test_config_does_not_load_blocked_plugin_from_args(pytester: Pytester) -> No result.stderr.fnmatch_lines(["*: error: unrecognized arguments: -s"]) assert result.ret == ExitCode.USAGE_ERROR + result = pytester.runpytest(str(p), "-p no:capture", "-s") + result.stderr.fnmatch_lines(["*: error: unrecognized arguments: -s"]) + assert result.ret == ExitCode.USAGE_ERROR + def test_invocation_args(pytester: Pytester) -> None: """Ensure that Config.invocation_* arguments are correctly defined"""