diff --git a/pyproject.toml b/pyproject.toml index 67229f1165..0b06e63168 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -284,7 +284,6 @@ ignore = [ 'FBT001', # Boolean positional arg in function definition 'FBT002', # Boolean default value in function definition 'FBT003', # Boolean positional value in function call - 'N806', # Variable `FType` in function should be lowercase 'N812', # Lowercase `__version_collection_doc_cache__` imported as non-lowercase `VERSION_CDC` 'N813', # Camelcase `Action` imported as lowercase `stdout_action` 'N817', # CamelCase `Constants` imported as acronym `C` diff --git a/tests/unit/actions/run/test_runner_async.py b/tests/unit/actions/run/test_runner_async.py index 16f01d3c1e..ee0c652b6e 100644 --- a/tests/unit/actions/run/test_runner_async.py +++ b/tests/unit/actions/run/test_runner_async.py @@ -132,15 +132,17 @@ def test_runner_args(mocker: MockerFixture, data: Scenario) -> None: args.entry("ansible_runner_timeout").value.current = data.timeout args.entry("ansible_runner_write_job_events").value.current = data.write_job_events - TestRunnerException = Exception + class TestRunnerError(Exception): + """Test runner exception.""" + command_async = mocker.patch( "ansible_navigator.actions.run.CommandAsync", - side_effect=TestRunnerException, + side_effect=TestRunnerError, ) run = action(args=args) run._queue = TEST_QUEUE # pylint: disable=protected-access - with pytest.raises(TestRunnerException): + with pytest.raises(TestRunnerError): run._run_runner() # pylint: disable=protected-access command_async.assert_called_once_with(**data.expected)