debian-forge/test
Tomas Hozza 9054da7d25 stages/firewall: fix fail when setting only the default zone
When the firewall stage is provided with stage options, which set only
the default firewall zone, the `firewall-offline-cmd` command is
executed unconditionally without any parameters. This is because in this
case `ports`, `enabled_services` and `disabled_services` are all an
empty lists. This results in a failure with the following error message:

`Opening of '/etc/sysconfig/system-config-firewall' failed, exiting.`

Make sure that the second invocation of `firewall-offline-cmd` happens
conditionally, only when at least one of the `ports`, `enabled_services`
or `disabled_services` is a non-empty list.

Adjust the stage test to cover this scenario.

Signed-off-by: Tomas Hozza <thozza@redhat.com>
2022-03-04 10:02:27 +01:00
..
cases Add the option of compressing using lz4 2022-01-11 13:20:11 +01:00
data stages/firewall: fix fail when setting only the default zone 2022-03-04 10:02:27 +01:00
mod test/lvm2: separate stdout and stderr 2022-03-04 08:42:35 +01:00
pipelines test: move all test manifests to get fedora packages from kernel mirrors 2020-06-07 22:08:34 +02:00
run test: fix executable test 2022-02-15 13:25:23 +00:00
src test: make TestBase inherit unittest.TestCase 2020-06-05 09:27:40 +02:00
.gitignore introduce testing script 2019-07-09 10:29:48 +02:00
__init__.py osbuild: add description() methods 2019-08-07 10:01:17 +02:00
initrd.py test/initrd: remove unneeded f-string 2021-02-16 22:58:15 +00:00
test.py test: capture full log in compile 2021-12-09 00:44:21 +00:00