public inbox for git-commits@fedoraproject.org
help / color / mirror / Atom feed
* [tests/selinux] pr775-checkpolicy-revdeps: fix homectl test case failures
@ 2026-09-11 13:22 Amith Kumar
  0 siblings, 0 replies; only message in thread
From: Amith Kumar @ 2026-09-11 13:22 UTC (permalink / raw)
  To: git-commits

            A new commit has been pushed.

            Repo   : tests/selinux
            Branch : pr775-checkpolicy-revdeps
            Commit : 6ed3370e171d469fabe4b0074229e43249901bb7
            Author : Amith Kumar <apeetham@redhat.com>
            Date   : 2025-04-23T08:32:25+05:30
            Stats  : +13/-8 in 1 file(s)
            URL    : https://src.fedoraproject.org/tests/selinux/c/6ed3370e171d469fabe4b0074229e43249901bb7?branch=pr775-checkpolicy-revdeps

            Log:
            fix homectl test case failures

The selinux-policy/systemd-homed test suite failed during recent test
run on Fedora-rawhide. Root cause of failure appears to be changed
behavior of command "homectl passwd". Fix the test code to address the
failures. Couple of other ERRORs are due to import failure of
selinux-policy/common library which is out-of-scope of this fix.

Signed-off-by: Amith Kumar <apeetham@redhat.com>

---
diff --git a/selinux-policy/systemd-homed/runtest.sh b/selinux-policy/systemd-homed/runtest.sh
index dd7969d..0776bb8 100755
--- a/selinux-policy/systemd-homed/runtest.sh
+++ b/selinux-policy/systemd-homed/runtest.sh
@@ -31,14 +31,18 @@
 
 PACKAGE1="selinux-policy"
 PACKAGE2="systemd"
+INSTALL_OPTION=""
+if dnf install --help | grep -q skip-broken ; then
+    INSTALL_OPTION="${INSTALL_OPTION} --skip-broken"
+fi
 
 function create_u() {
 expect -f  - <<<'
     set timeout -1
     spawn homectl create test_u --disk-size=500M
-    expect "*: "
+    expect "*test_u: "
     send -- "Red_123hat\r"
-    expect "*: "
+    expect "*test_u*: "
     send -- "Red_123hat\r"
     expect eof
     foreach {pid spawnid os_error_flag value} [wait] break
@@ -74,10 +78,12 @@ function passwd_u() {
 expect -f  - <<<'
    set timeout -1
    spawn homectl passwd test_u
-   expect "*: "
+   expect "*test_u: "
    send -- "Sim_123pl1\r"
-   expect "*: "
+   expect "*test_u*: "
    send -- "Sim_123pl1\r"
+   expect "*test_u: "
+   send -- "Red_123hat\r"
    expect eof
    foreach {pid spawnid os_error_flag value} [wait] break
    exit $value
@@ -88,7 +94,7 @@ function auth_u() {
 expect -f  - <<<'
    set timeout -1
    spawn homectl authenticate test_u
-   expect "*: "
+   expect "*test_u: "
    send -- "Sim_123pl1\r"
    expect eof
    foreach {pid spawnid os_error_flag value} [wait] break
@@ -100,7 +106,7 @@ function resize_u() {
 expect -f  - <<<'
    set timeout -1
    spawn homectl resize test_u 425.0M
-   expect "*: "
+   expect "*test_u: "
    send -- "Sim_123pl1\r"
    expect eof
    foreach {pid spawnid os_error_flag value} [wait] break
@@ -153,7 +159,7 @@ rlJournalStart
     rlPhaseStartTest "homectl inspect"
         sleep 20
         tst_Time="$(date '+%T')"
-        rlRun "homectl inspect test_u"
+        rlRun "homectl inspect test_u --no-pager"
         sleep 5
         rlRun "ausearch -m AVC -m USER_AVC --start $tst_Time --input-logs" 1
     rlPhaseEnd
@@ -221,7 +227,6 @@ rlJournalStart
         rlSEMatchPathCon "/var/cache/systemd/" "systemd_cache_t"
         rlSEMatchPathCon "/var/cache/systemd/home/" "systemd_homed_cache_t"
         rlSESearchRule "allow systemd_homed_t systemd_homed_cache_t : dir { read } [ ]"
-
         rlRun "service systemd-homed restart"
     rlPhaseEnd
 

^ permalink raw reply related	[flat|nested] only message in thread

only message in thread, other threads:[~2026-09-11 13:22 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:22 [tests/selinux] pr775-checkpolicy-revdeps: fix homectl test case failures Amith Kumar

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox