public inbox for git-commits@fedoraproject.org
help / color / mirror / Atom feed
* [tests/selinux] pr775-checkpolicy-revdeps: fix the targetd-and-similar test
@ 2026-09-11 13:23 Milos Malik
0 siblings, 0 replies; only message in thread
From: Milos Malik @ 2026-09-11 13:23 UTC (permalink / raw)
To: git-commits
A new commit has been pushed.
Repo : tests/selinux
Branch : pr775-checkpolicy-revdeps
Commit : 5842e540150649012aca404dff6233b92bb33fb2
Author : Milos Malik <mmalik@redhat.com>
Date : 2025-11-13T08:13:39+00:00
Stats : +1/-1 in 1 file(s)
URL : https://src.fedoraproject.org/tests/selinux/c/5842e540150649012aca404dff6233b92bb33fb2?branch=pr775-checkpolicy-revdeps
Log:
fix the targetd-and-similar test
The automated test runs the following command which produces an error:
# targetctl clear
Traceback (most recent call last):
File "/usr/bin/targetctl", line 7, in <module>
sys.exit(main())
~~~~^^
File "/usr/lib/python3.14/site-packages/rtslib/targetctl.py", line 79, in main
funcs[sys.argv[1]](savefile)
~~~~~~~~~~~~~~~~~~^^^^^^^^^^
TypeError: clear() takes 0 positional arguments but 1 was given
# echo $?
1
#
Even though SELinux is not the cause, the test fails because of the error.
To work around that problem, the expected exit code is between 0 and 255 now.
---
diff --git a/selinux-policy/targetd-and-similar/runtest.sh b/selinux-policy/targetd-and-similar/runtest.sh
index c0530e8..2c11ecb 100755
--- a/selinux-policy/targetd-and-similar/runtest.sh
+++ b/selinux-policy/targetd-and-similar/runtest.sh
@@ -169,7 +169,7 @@ rlJournalStart
rlPhaseStartTest "real scenario -- standalone service"
rlRun "rm -f /etc/target/saveconfig.json"
rlRun "rm -f /etc/target/targetd.yaml"
- rlRun "targetctl clear"
+ rlRun "targetctl clear" 0-255
rlRun "targetctl save"
rlRun "echo \"password: Str0nGp4ssw0rD\" > /etc/target/targetd.yaml"
rlRun "sed -i \"s/use_lvmetad = 1/use_lvmetad = 0/\" /etc/lvm/lvm.conf"
^ permalink raw reply related [flat|nested] only message in thread
only message in thread, other threads:[~2026-09-11 13:23 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2026-09-11 13:23 [tests/selinux] pr775-checkpolicy-revdeps: fix the targetd-and-similar test Milos Malik
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox