Modify conditions for selinux integratuion tests

Signed-off-by: Hideki Saito <saito@fgrep.org>
This commit is contained in:
Hideki Saito 2024-10-15 17:10:56 +09:00
parent daca208c0b
commit 2f095566c7
No known key found for this signature in database
GPG key ID: 3E1D43AA010AC50A
2 changed files with 5 additions and 2 deletions

View file

@ -0,0 +1,3 @@
---
trivial:
- selinux - conditions for selinux integration tests have been modified to be more accurate.

View file

@ -128,8 +128,8 @@
ansible.builtin.assert:
that:
- selinux_config_original | length == selinux_config_after | length
- selinux_config_after[selinux_config_after.index('SELINUX=disabled')] is search("^SELINUX=\w+$")
- selinux_config_after[selinux_config_after.index('SELINUXTYPE=targeted')] is search("^SELINUXTYPE=\w+$")
- (selinux_config_after | select("search", "^SELINUX=disabled\s*$") | list | length) > 0
- (selinux_config_after | select("search", "^SELINUXTYPE=targeted\s*$") | list | length) > 0
- name: TEST 1 | Disable SELinux again, with kernel arguments update
ansible.posix.selinux: