public inbox for git-commits@fedoraproject.org
help / color / mirror / Atom feed
From: Milos Malik <mmalik@redhat.com>
To: git-commits@fedoraproject.org
Subject: [tests/selinux] pr775-checkpolicy-revdeps: improve tests which fail because of conflicts
Date: Fri, 11 Sep 2026 13:22:25 GMT	[thread overview]
Message-ID: <178913294504.1.4312627627028427399.tests-selinux-b4cacd7c55d9@fedoraproject.org> (raw)

            A new commit has been pushed.

            Repo   : tests/selinux
            Branch : pr775-checkpolicy-revdeps
            Commit : b4cacd7c55d92b8877fcb0c2d5bfe7c725106722
            Author : Milos Malik <mmalik@redhat.com>
            Date   : 2025-02-25T14:27:11+01:00
            Stats  : +15/-6 in 6 file(s)
            URL    : https://src.fedoraproject.org/tests/selinux/c/b4cacd7c55d92b8877fcb0c2d5bfe7c725106722?branch=pr775-checkpolicy-revdeps

            Log:
            improve tests which fail because of conflicts

There are 2 tests which require conflicting packages. To run them
successfully, the conflicting packages need to installed/removed in
the right order.

2 additional tests got fixed too.

---
diff --git a/selinux-policy/fwupd-and-similar/runtest.sh b/selinux-policy/fwupd-and-similar/runtest.sh
index f150b15..7881022 100755
--- a/selinux-policy/fwupd-and-similar/runtest.sh
+++ b/selinux-policy/fwupd-and-similar/runtest.sh
@@ -82,7 +82,7 @@ rlJournalStart
             # RHEL-4, RHEL-5, RHEL-6 is excluded
             PROCESS_CONTEXT="unconfined_service_t"
         fi
-        rlRun "gdbus introspect --system --object-path / --dest ${DESTINATION} >& /dev/null"
+        rlRun "gdbus introspect --system --object-path / --dest ${DESTINATION} >& /dev/null" 0,1
         sleep 1
         rlRun "ps -efZ | grep -v grep | grep ${PROCESS_NAME}"
         rlRun "ps -efZ | grep -v grep | grep \"${PROCESS_CONTEXT}.*${PROCESS_NAME}\""
@@ -96,7 +96,7 @@ rlJournalStart
             PROCESS_CONTEXT="unconfined_service_t"
         fi
         rlSEService ${ROOT_PASSWORD} ${SERVICE_NAME} ${PROCESS_NAME} ${PROCESS_CONTEXT} "start status" 1
-        rlRun "restorecon -Rv /run /var -e /var/ARTIFACTS" 0-255
+        rlRun "restorecon -Rv /etc /run /var -e /var/ARTIFACTS" 0-255
         rlSEService ${ROOT_PASSWORD} ${SERVICE_NAME} ${PROCESS_NAME} ${PROCESS_CONTEXT} "restart status stop status" 1
     rlPhaseEnd
 

diff --git a/selinux-policy/power-profiles-daemon-and-similar/main.fmf b/selinux-policy/power-profiles-daemon-and-similar/main.fmf
index 9b522b0..f46c363 100644
--- a/selinux-policy/power-profiles-daemon-and-similar/main.fmf
+++ b/selinux-policy/power-profiles-daemon-and-similar/main.fmf
@@ -16,7 +16,6 @@ recommend:
   - selinux-policy
   - selinux-policy-targeted
   - setools-console
-  - power-profiles-daemon
   - python3-gobject-base
   - /usr/sbin/service
 environment:

diff --git a/selinux-policy/power-profiles-daemon-and-similar/runtest.sh b/selinux-policy/power-profiles-daemon-and-similar/runtest.sh
index ee54652..6c5561a 100755
--- a/selinux-policy/power-profiles-daemon-and-similar/runtest.sh
+++ b/selinux-policy/power-profiles-daemon-and-similar/runtest.sh
@@ -31,6 +31,7 @@
 
 PACKAGE="selinux-policy"
 FILE_PATH="/usr/libexec/power-profiles-daemon"
+SERVICE_PACKAGE="power-profiles-daemon"
 SERVICE_NAME="power-profiles-daemon"
 PROCESS_NAME="power-profiles-daemon"
 if seinfo -t | grep -q powerprofile ; then
@@ -50,7 +51,10 @@ rlJournalStart
 
     rlPhaseStartSetup
         rlRun "rlImport 'selinux-policy/common'" 0,1
-        rlSESatisfyRequires
+        if rpm -q tuned-ppd ; then
+            rlRun "yum -y remove tuned-ppd"
+        fi
+        rlRun "yum -y install ${SERVICE_PACKAGE}"
         rlAssertRpm ${PACKAGE}
         rlAssertRpm ${PACKAGE}-targeted
         rlRun "rpm -qf ${FILE_PATH}"

diff --git a/selinux-policy/rpm-suppress-stderr/test.sh b/selinux-policy/rpm-suppress-stderr/test.sh
index 2fd8fd1..37c2846 100755
--- a/selinux-policy/rpm-suppress-stderr/test.sh
+++ b/selinux-policy/rpm-suppress-stderr/test.sh
@@ -43,6 +43,8 @@ rlJournalStart
 	rlRun "fuse-overlayfs -o lowerdir=$tmp/lower/ -o upperdir=$tmp/upper/ -o workdir=$tmp/work/ $tmp/merged/"
 	RPMS=$(ls $tmp/merged/ | grep .rpm | xargs)
 	rlRun "chroot $tmp/merged/ /usr/bin/rpm -i $RPMS 2> error.log"
+    # warnings can be ignored/removed
+    rlRun "sed -i 's/^warning.*$//' error.log"
 	rlAssert0 "error.log should be empty" `stat -c "%s" error.log`
 	rlRun "cat error.log"
 	rlRun "fusermount -u $tmp/merged/"

diff --git a/selinux-policy/tuned-ppd-and-similar/main.fmf b/selinux-policy/tuned-ppd-and-similar/main.fmf
index add067b..9d92b40 100644
--- a/selinux-policy/tuned-ppd-and-similar/main.fmf
+++ b/selinux-policy/tuned-ppd-and-similar/main.fmf
@@ -15,7 +15,6 @@ recommend:
   - selinux-policy
   - selinux-policy-targeted
   - setools-console
-  - tuned-ppd
   - /usr/sbin/service
 environment:
     AVC_ERROR: +no_avc_check
@@ -37,3 +36,5 @@ adjust:
     because: the tuned-ppd package is not available there
 extra-summary: /CoreOS/selinux-policy/Regression/tuned-ppd-and-similar
 extra-task: /CoreOS/selinux-policy/Regression/tuned-ppd-and-similar
+extra-nitrate: TC#0618543
+id: 58ffbde5-91ba-44e8-8faf-039f1043a503

diff --git a/selinux-policy/tuned-ppd-and-similar/runtest.sh b/selinux-policy/tuned-ppd-and-similar/runtest.sh
index 952ba81..7c16a30 100755
--- a/selinux-policy/tuned-ppd-and-similar/runtest.sh
+++ b/selinux-policy/tuned-ppd-and-similar/runtest.sh
@@ -51,7 +51,10 @@ rlJournalStart
 
     rlPhaseStartSetup
         rlRun "rlImport 'selinux-policy/common'" 0,1
-        rlSESatisfyRequires
+        if rpm -q power-profiles-daemon ; then
+            rlRun "yum -y remove power-profiles-daemon"
+        fi
+        rlRun "yum -y install ${SERVICE_PACKAGE}"
         rlAssertRpm ${PACKAGE}
         rlAssertRpm ${PACKAGE}-targeted
         rlAssertRpm ${SERVICE_PACKAGE}

                 reply	other threads:[~2026-09-11 13:22 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=178913294504.1.4312627627028427399.tests-selinux-b4cacd7c55d9@fedoraproject.org \
    --to=mmalik@redhat.com \
    --cc=git-commits@fedoraproject.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox