[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PATCH] tests: avoid a "make check-root" failure when mcstransd is runni
From: |
Jim Meyering |
Subject: |
[PATCH] tests: avoid a "make check-root" failure when mcstransd is running |
Date: |
Wed, 30 Apr 2008 23:32:40 +0200 |
and one more:
tests: avoid a "make check-root" failure when mcstransd is running
* tests/misc/chcon: Skip this test if mcstransd seems to be running.
diff --git a/tests/misc/chcon b/tests/misc/chcon
index 3a61c69..74248a3 100755
--- a/tests/misc/chcon
+++ b/tests/misc/chcon
@@ -11,6 +11,16 @@ fi
require_root_
require_selinux_
+# When mcstransd is running, you'll see only the 3-component
+# version of file-system context strings. Detect that,
+# and if it's running, skip this test.
+ctx=$(stat --printf='%C\n' .) || framework_failure
+case $ctx in
+ *:*:*:*) ;; # four components is ok
+ *) # anything else probably means mcstransd is running
+ skip_test_ "unexpected context '$ctx'; turn off mcstransd" ;;
+esac
+
mkdir -p d/sub/s2 || framework_failure
touch f g d/sub/1 d/sub/2 || framework_failure
--
1.5.5.1.100.g9a8d
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [PATCH] tests: avoid a "make check-root" failure when mcstransd is running,
Jim Meyering <=