public inbox for git-commits@fedoraproject.org
help / color / mirror / Atom feed
* [tests/selinux] pr775-checkpolicy-revdeps: Test if selinux-policy owns tree with interface files
@ 2026-09-11 13:23 Veronika Syncakova
  0 siblings, 0 replies; only message in thread
From: Veronika Syncakova @ 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 : fdcacccc89cedef323f2188c59f2b6f615b236fd
            Author : Veronika Syncakova <veva.syncakova@gmail.com>
            Date   : 2026-04-08T08:45:47+00:00
            Stats  : +72/-0 in 2 file(s)
            URL    : https://src.fedoraproject.org/tests/selinux/c/fdcacccc89cedef323f2188c59f2b6f615b236fd?branch=pr775-checkpolicy-revdeps

            Log:
            Test if selinux-policy owns tree with interface files

Recently filed report revealed that certain files are not owned by the selinux-policy package.
This situation is generally described in the following document and should be fixed:

    https://docs.fedoraproject.org/en-US/packaging-guidelines/UnownedDirectories/

Purpose of this test is to find out if the issue is fixed or not.

TC coveres: RHEL-141659 + RHEL-157952 + FC-1681

---
diff --git a/selinux-policy/files-ownership/main.fmf b/selinux-policy/files-ownership/main.fmf
new file mode 100644
index 0000000..9808d2d
--- /dev/null
+++ b/selinux-policy/files-ownership/main.fmf
@@ -0,0 +1,25 @@
+summary: test if selinux-policy owns tree with interface files
+contact: Veronika Syncakova <vsyncako@redhat.com>
+test: ./runtest.sh
+duration: 5m
+enabled: true
+require:
+  - selinux-policy
+recommend:
+  - selinux-policy-targeted
+  - selinux-policy-mls
+  - selinux-policy-minimum
+tag:
+  - NoRHEL4
+  - NoRHEL5
+  - NoRHEL6
+  - NoRHEL7
+  - NoRHEL8
+adjust+:
+  - enabled: false
+    when: distro == rhel-4, rhel-5, rhel-6, rhel-7, rhel-8
+    continue: false
+link:
+  - verifies: https://redhat.atlassian.net/browse/RHEL-141659
+  - verifies: https://redhat.atlassian.net/browse/RHEL-157952
+  - verifies: https://redhat.atlassian.net/browse/FC-1681
\ No newline at end of file

diff --git a/selinux-policy/files-ownership/runtest.sh b/selinux-policy/files-ownership/runtest.sh
new file mode 100755
index 0000000..d5e79f1
--- /dev/null
+++ b/selinux-policy/files-ownership/runtest.sh
@@ -0,0 +1,47 @@
+#!/bin/bash
+# vim: dict+=/usr/share/beakerlib/dictionary.vim cpt=.,w,b,u,t,i,k
+# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+#
+#   runtest.sh of selinux-policy/files-ownership/runtest.sh
+#   Description: test if selinux-policy owns tree with interface files
+#   Author: Veronika Syncakova <vsyncako@redhat.com>
+#
+# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+#
+#   Copyright (c) 2026 Red Hat, Inc.
+#
+#   This program is free software: you can redistribute it and/or
+#   modify it under the terms of the GNU General Public License as
+#   published by the Free Software Foundation, either version 2 of
+#   the License, or (at your option) any later version.
+#
+#   This program is distributed in the hope that it will be
+#   useful, but WITHOUT ANY WARRANTY; without even the implied
+#   warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
+#   PURPOSE.  See the GNU General Public License for more details.
+#
+#   You should have received a copy of the GNU General Public License
+#   along with this program. If not, see http://www.gnu.org/licenses/.
+#
+# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+
+# Include Beaker environment
+. /usr/share/beakerlib/beakerlib.sh || exit 1
+
+rlJournalStart
+    rlPhaseStartSetup
+        rlAssertRpm selinux-policy
+    rlPhaseEnd
+
+    rlPhaseStartTest "RHEL-141659 + RHEL-157952 + FC-1681"
+        for LOCATION in devel devel/include devel/include/distributed \
+            packages/targeted packages/minimum packages/mls; do
+            rlRun -s "rpm -qf /usr/share/selinux/${LOCATION}"
+            rlAssertGrep "selinux-policy-" $rlRun_LOG -i
+            rm -f $rlRun_LOG
+        done
+    rlPhaseEnd
+
+    rlPhaseStartCleanup
+    rlPhaseEnd
+rlJournalEnd
\ No newline at end of file

^ 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: Test if selinux-policy owns tree with interface files Veronika Syncakova

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