From owner-svn-src-head@freebsd.org Sat Sep 3 17:59:47 2016 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 8911BBCEA0B; Sat, 3 Sep 2016 17:59:47 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 3844A926; Sat, 3 Sep 2016 17:59:47 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id u83HxklB073534; Sat, 3 Sep 2016 17:59:46 GMT (envelope-from ngie@FreeBSD.org) Received: (from ngie@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id u83HxkTI073533; Sat, 3 Sep 2016 17:59:46 GMT (envelope-from ngie@FreeBSD.org) Message-Id: <201609031759.u83HxkTI073533@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: ngie set sender to ngie@FreeBSD.org using -f From: Ngie Cooper Date: Sat, 3 Sep 2016 17:59:46 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r305357 - head/tests/sys/mac/bsdextended X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.22 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 03 Sep 2016 17:59:47 -0000 Author: ngie Date: Sat Sep 3 17:59:46 2016 New Revision: 305357 URL: https://svnweb.freebsd.org/changeset/base/305357 Log: Skip testcases 9/10 if jail(8) isn't installed These testcases require jail support MFC after: 1 week Sponsored by: EMC / Isilon Storage Division Modified: head/tests/sys/mac/bsdextended/matches_test.sh Modified: head/tests/sys/mac/bsdextended/matches_test.sh ============================================================================== --- head/tests/sys/mac/bsdextended/matches_test.sh Sat Sep 3 17:31:13 2016 (r305356) +++ head/tests/sys/mac/bsdextended/matches_test.sh Sat Sep 3 17:59:46 2016 (r305357) @@ -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 #