do not use set_defaults for architecture arguments

according to the source code defaults always updates the values
dictionary. This in this specific case it is impossible to override the
value it will be always empty list.

In order to handle it we are adding another property to the Handler
class which allows to run with None architecture list.

This particular set_defaults behaviour is still useful for other cases
when we have to run command without any specific architecture
This commit is contained in:
2021-10-03 00:59:24 +03:00
parent 4f06647193
commit 59f2992559
23 changed files with 190 additions and 54 deletions

View File

@ -31,6 +31,13 @@ def test_run(args: argparse.Namespace, configuration: Configuration, mocker: Moc
run_mock.assert_called_once()
def test_disallow_auto_architecture_run() -> None:
"""
must not allow multi architecture run
"""
assert not Web.ALLOW_AUTO_ARCHITECTURE_RUN
def test_disallow_multi_architecture_run() -> None:
"""
must not allow multi architecture run