public inbox for git-commits@fedoraproject.org
help / color / mirror / Atom feed
* [tests/selinux] pr775-checkpolicy-revdeps: checkpolicy/checkpolicy: Grep for error messages rather than debug logs
@ 2026-09-11 13:17 Petr Lautrbach
0 siblings, 0 replies; only message in thread
From: Petr Lautrbach @ 2026-09-11 13:17 UTC (permalink / raw)
To: git-commits
A new commit has been pushed.
Repo : tests/selinux
Branch : pr775-checkpolicy-revdeps
Commit : a207b0ec49d167b5eef060a934cf35eddfbb4629
Author : Petr Lautrbach <plautrba@redhat.com>
Date : 2019-04-09T15:23:30+02:00
Stats : +4/-2 in 1 file(s)
URL : https://src.fedoraproject.org/tests/selinux/c/a207b0ec49d167b5eef060a934cf35eddfbb4629?branch=pr775-checkpolicy-revdeps
Log:
checkpolicy/checkpolicy: Grep for error messages rather than debug logs
checkpolicy was updated in 2.9 in order not to write debug messages on ouput. It
doesn't output "loading policy ..." messages anymore.
See https://github.com/SELinuxProject/selinux/commit/854fdc1ac40720782491e8ada6837aa4550a7ca1
Fixes:
[ PASS ] :: Command 'checkpolicy >& /tmp/tmp.NMYnXbEmez' (Expected 1, got 1)
[ FAIL ] :: File '/tmp/tmp.NMYnXbEmez' should contain 'loading policy configuration from policy.conf'
[ PASS ] :: Command 'checkpolicy -b >& /tmp/tmp.NMYnXbEmez' (Expected 1, got 1)
[ FAIL ] :: File '/tmp/tmp.NMYnXbEmez' should contain 'loading policy configuration from policy'
---
diff --git a/checkpolicy/checkpolicy/runtest.sh b/checkpolicy/checkpolicy/runtest.sh
index 815dbaf..7bdfbba 100644
--- a/checkpolicy/checkpolicy/runtest.sh
+++ b/checkpolicy/checkpolicy/runtest.sh
@@ -43,6 +43,7 @@ rlJournalStart
TEST_DIR=`mktemp -d`
OUTPUT_FILE=`mktemp`
rlAssertExists "/usr/bin/checkpolicy"
+ rlAssertExists "/usr/share/man/man8/checkpolicy.8.gz"
rlPhaseEnd
rlPhaseStartTest "compilation from policy.conf"
@@ -68,9 +69,9 @@ rlJournalStart
rlPhaseStartTest
rlRun "checkpolicy >& ${TEST_FILE}" 1
- rlAssertGrep "loading policy configuration from policy.conf" ${TEST_FILE}
+ rlAssertGrep "unable to open policy.conf" ${TEST_FILE}
rlRun "checkpolicy -b >& ${TEST_FILE}" 1
- rlAssertGrep "loading policy configuration from policy" ${TEST_FILE}
+ rlAssertGrep "Can't open 'policy': No such file or directory" ${TEST_FILE}
rlRun "checkpolicy -V"
rlRun "checkpolicy -U 2>&1 | grep \"option requires an argument\""
rlRun "checkpolicy -U xyz" 1
@@ -97,6 +98,7 @@ rlJournalStart
rlRun "checkpolicy -c 0 2>&1 | grep \"value 0 not in range\""
rlRun "checkpolicy -t 2>&1 | grep \"option requires an argument\""
rlRun "checkpolicy -t xyz 2>&1 | grep -i \"unknown target platform\""
+ rlRun "man checkpolicy | col -b | grep -- '-m]'" 1
rlRun "checkpolicy --help 2>&1 | grep -- '-m]'" 1
rlPhaseEnd
^ permalink raw reply related [flat|nested] only message in thread
only message in thread, other threads:[~2026-09-11 13:17 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:17 [tests/selinux] pr775-checkpolicy-revdeps: checkpolicy/checkpolicy: Grep for error messages rather than debug logs Petr Lautrbach
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox