Date: Sun, 18 Sep 2016 04:34:33 +0000 (UTC) From: Ngie Cooper <ngie@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org Subject: svn commit: r305915 - stable/10/tests/sys/mac/bsdextended Message-ID: <201609180434.u8I4YXfh028793@repo.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: ngie Date: Sun Sep 18 04:34:32 2016 New Revision: 305915 URL: https://svnweb.freebsd.org/changeset/base/305915 Log: MFstable/11 r305914: MFC r305357: Skip testcases 9/10 if jail(8) isn't installed These testcases require jail support Modified: stable/10/tests/sys/mac/bsdextended/matches_test.sh Directory Properties: stable/10/ (props changed) Modified: stable/10/tests/sys/mac/bsdextended/matches_test.sh ============================================================================== --- stable/10/tests/sys/mac/bsdextended/matches_test.sh Sun Sep 18 04:19:43 2016 (r305914) +++ stable/10/tests/sys/mac/bsdextended/matches_test.sh Sun Sep 18 04:34:32 2016 (r305915) @@ -144,30 +144,36 @@ else fail $desc fi -# -# Subject Match on jail -# -rm -f $playground/test-jail - -desc="subject matching jailid" -jailid=`jail -i / localhost 127.0.0.1 /usr/sbin/daemon -f /bin/sh -c "(sleep 5; touch $playground/test-jail) &"` -ugidfw set 1 subject jailid $jailid object mode rasx -sleep 10 - -if [ -f $playground/test-jail ]; then - fail "TODO $desc: this testcase fails (see bug # 205481)" -else - pass $desc -fi - -rm -f $playground/test-jail -desc="subject nonmatching jailid" -jailid=`jail -i / localhost 127.0.0.1 /usr/sbin/daemon -f /bin/sh -c "(sleep 5; touch $playground/test-jail) &"` -sleep 10 -if [ -f $playground/test-jail ]; then - pass $desc -else - fail $desc +if which jail >/dev/null; then + # + # Subject Match on jail + # + rm -f $playground/test-jail + + desc="subject matching jailid" + jailid=`jail -i / localhost 127.0.0.1 /usr/sbin/daemon -f /bin/sh -c "(sleep 5; touch $playground/test-jail) &"` + ugidfw set 1 subject jailid $jailid object mode rasx + sleep 10 + + if [ -f $playground/test-jail ]; then + fail "TODO $desc: this testcase fails (see bug # 205481)" + else + pass $desc + fi + + rm -f $playground/test-jail + desc="subject nonmatching jailid" + jailid=`jail -i / localhost 127.0.0.1 /usr/sbin/daemon -f /bin/sh -c "(sleep 5; touch $playground/test-jail) &"` + sleep 10 + if [ -f $playground/test-jail ]; then + pass $desc + else + fail $desc + fi +else + # XXX: kyua is too dumb to parse skip ranges, still.. + pass "skip jail(8) not installed" + pass "skip jail(8) not installed" fi #
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201609180434.u8I4YXfh028793>