svn commit: r275504 - in stable/10: . contrib/pjdfstest contrib/pjdfstest/tests/chflags contrib/pjdfstest/tests/chmod contrib/pjdfstest/tests/chown contrib/pjdfstest/tests/ftruncate contrib/pjdfste...

Garrett Cooper ngie at FreeBSD.org
Fri Dec 5 11:44:27 UTC 2014


Author: ngie
Date: Fri Dec  5 11:44:18 2014
New Revision: 275504
URL: https://svnweb.freebsd.org/changeset/base/275504

Log:
  MFC r272057,r272083,r272084,r272087,r274016:
  
  r272057:
  
    Import pjdfstest from ^/vendor/pjdfstest/abf03c3a47745d4521b0e4aa141317553ca48f91
  
    - Remove tools/regression/pjdfstest
    - Add upgrade directions for contrib/pjdfstest
    - Add a note to UPDATING for the move (the reachover Makefiles are coming
      soon)
  
    Functional differences:
    - ftruncate testcases are added from upstream (github)
  
    Non-functional differences:
    - The copyright for the project has been updated to 2012
    - pjd's contact information has been updated
  
    Discussed with: -testing, jmmv, pjd
    Sponsored by: EMC / Isilon Storage Division
  
  r272083:
  
    Expect ELOOP on Darwin/Linux with "O_NOFOLLOW was specified and the target is a
    symbolic link" case. Assume EMLINK on the rest of the OSes (FreeBSD, Solaris,
    etc)
  
    Sponsored by: EMC / Isilon Storage Division
  
  r272084:
  
    Fix the executed testplan count
  
    Sponsored by: EMC / Isilon Storage Division
  
  r272087:
  
    Increase the memory disk size in the following testcases to avoid mount
    failures, which would cause cascade failures in the rest of the test
    run:
  
    link/15.t, open/19.t, mkdir/11.t, mkfifo/11.t, symlink/11.t
  
    Fail quickly in all of the testcases if mdconfig, mount, umount, etc
    fails to avoid issues similar to this in the future
  
    Submitted by: Casey Peel <cpeel at isilon.com>
    Sponsored by: EMC / Isilon Storage Division
  
  r274016:
  
    Integrate pjdfstest test suite execution into kyua
  
    pjdfstest execution is opt-in and must be done as root due to some of the
    assumptions made by the test suite and lack of error checking in the non-root
    case
  
    A description of how to execute pjdfstest with kyua is provided in
    share/pjdfstest/README
  
    Phabric: D824 (an earlier prototype patch)
    Relnotes: yes
    Sponsored by: EMC / Isilon Storage Division

Added:
  stable/10/contrib/pjdfstest/
     - copied from r272057, head/contrib/pjdfstest/
  stable/10/share/doc/pjdfstest/
     - copied from r274016, head/share/doc/pjdfstest/
  stable/10/tests/sys/pjdfstest/
     - copied from r274016, head/tests/sys/pjdfstest/
Modified:
  stable/10/UPDATING
  stable/10/contrib/pjdfstest/tests/chflags/12.t
  stable/10/contrib/pjdfstest/tests/chmod/09.t
  stable/10/contrib/pjdfstest/tests/chown/09.t
  stable/10/contrib/pjdfstest/tests/ftruncate/00.t
  stable/10/contrib/pjdfstest/tests/ftruncate/10.t
  stable/10/contrib/pjdfstest/tests/link/05.t
  stable/10/contrib/pjdfstest/tests/link/14.t
  stable/10/contrib/pjdfstest/tests/link/15.t
  stable/10/contrib/pjdfstest/tests/link/16.t
  stable/10/contrib/pjdfstest/tests/mkdir/09.t
  stable/10/contrib/pjdfstest/tests/mkdir/11.t
  stable/10/contrib/pjdfstest/tests/mkfifo/08.t
  stable/10/contrib/pjdfstest/tests/mkfifo/11.t
  stable/10/contrib/pjdfstest/tests/open/14.t
  stable/10/contrib/pjdfstest/tests/open/15.t
  stable/10/contrib/pjdfstest/tests/open/16.t
  stable/10/contrib/pjdfstest/tests/open/19.t
  stable/10/contrib/pjdfstest/tests/rename/15.t
  stable/10/contrib/pjdfstest/tests/rename/16.t
  stable/10/contrib/pjdfstest/tests/rmdir/13.t
  stable/10/contrib/pjdfstest/tests/rmdir/14.t
  stable/10/contrib/pjdfstest/tests/symlink/10.t
  stable/10/contrib/pjdfstest/tests/symlink/11.t
  stable/10/contrib/pjdfstest/tests/truncate/10.t
  stable/10/contrib/pjdfstest/tests/unlink/12.t
  stable/10/etc/mtree/BSD.tests.dist
  stable/10/share/doc/Makefile
  stable/10/tests/sys/Makefile
  stable/10/tools/build/mk/OptionalObsoleteFiles.inc
Directory Properties:
  stable/10/   (props changed)

Modified: stable/10/UPDATING
==============================================================================
--- stable/10/UPDATING	Fri Dec  5 10:23:18 2014	(r275503)
+++ stable/10/UPDATING	Fri Dec  5 11:44:18 2014	(r275504)
@@ -16,6 +16,11 @@ from older versions of FreeBSD, try WITH
 stable/10, and then rebuild without this option. The bootstrap process from
 older version of current is a bit fragile.
 
+20141205:
+	pjdfstest has been integrated into kyua as an opt-in test suite.
+	Please see share/doc/pjdfstest/README for a more details on how to
+	execute it.
+
 20141118:
 	10.1-RELEASE.
 

Modified: stable/10/contrib/pjdfstest/tests/chflags/12.t
==============================================================================
--- head/contrib/pjdfstest/tests/chflags/12.t	Wed Sep 24 07:00:35 2014	(r272057)
+++ stable/10/contrib/pjdfstest/tests/chflags/12.t	Fri Dec  5 11:44:18 2014	(r275504)
@@ -16,8 +16,8 @@ FreeBSD:UFS)
 	n1=`namegen`
 
 	expect 0 mkdir ${n0} 0755
-	n=`mdconfig -a -n -t malloc -s 1m`
-	newfs /dev/md${n} >/dev/null
+	n=`mdconfig -a -n -t malloc -s 1m` || exit
+	newfs /dev/md${n} >/dev/null || exit
 	mount /dev/md${n} ${n0}
 	expect 0 create ${n0}/${n1} 0644
 	expect 0 chflags ${n0}/${n1} UF_IMMUTABLE
@@ -34,7 +34,7 @@ FreeBSD:UFS)
 	expect none stat ${n0}/${n1} flags
 	expect 0 unlink ${n0}/${n1}
 	umount /dev/md${n}
-	mdconfig -d -u ${n}
+	mdconfig -d -u ${n} || exit
 	expect 0 rmdir ${n0}
 	;;
 FreeBSD:ZFS)
@@ -43,7 +43,7 @@ FreeBSD:ZFS)
 	n0=`namegen`
 	n1=`namegen`
 
-	n=`mdconfig -a -n -t malloc -s 128m`
+	n=`mdconfig -a -n -t malloc -s 128m` || exit
 	zpool create ${n0} /dev/md${n}
 	expect 0 create /${n0}/${n1} 0644
 	expect 0 chflags /${n0}/${n1} UF_NODUMP
@@ -60,7 +60,7 @@ FreeBSD:ZFS)
 	expect none stat /${n0}/${n1} flags
 	expect 0 unlink /${n0}/${n1}
 	zpool destroy ${n0}
-	mdconfig -d -u ${n}
+	mdconfig -d -u ${n} || exit
 	;;
 *)
 	quick_exit

Modified: stable/10/contrib/pjdfstest/tests/chmod/09.t
==============================================================================
--- head/contrib/pjdfstest/tests/chmod/09.t	Wed Sep 24 07:00:35 2014	(r272057)
+++ stable/10/contrib/pjdfstest/tests/chmod/09.t	Fri Dec  5 11:44:18 2014	(r275504)
@@ -14,9 +14,9 @@ n0=`namegen`
 n1=`namegen`
 
 expect 0 mkdir ${n0} 0755
-n=`mdconfig -a -n -t malloc -s 1m`
-newfs /dev/md${n} >/dev/null
-mount /dev/md${n} ${n0}
+n=`mdconfig -a -n -t malloc -s 1m` || exit
+newfs /dev/md${n} >/dev/null || exit
+mount /dev/md${n} ${n0} || exit
 expect 0 create ${n0}/${n1} 0644
 expect 0 chmod ${n0}/${n1} 0640
 expect 0640 stat ${n0}/${n1} mode
@@ -33,5 +33,5 @@ expect 0 lchmod ${n0}/${n1} 0640
 expect 0640 stat ${n0}/${n1} mode
 expect 0 unlink ${n0}/${n1}
 umount /dev/md${n}
-mdconfig -d -u ${n}
+mdconfig -d -u ${n} || exit
 expect 0 rmdir ${n0}

Modified: stable/10/contrib/pjdfstest/tests/chown/09.t
==============================================================================
--- head/contrib/pjdfstest/tests/chown/09.t	Wed Sep 24 07:00:35 2014	(r272057)
+++ stable/10/contrib/pjdfstest/tests/chown/09.t	Fri Dec  5 11:44:18 2014	(r275504)
@@ -14,9 +14,9 @@ n0=`namegen`
 n1=`namegen`
 
 expect 0 mkdir ${n0} 0755
-n=`mdconfig -a -n -t malloc -s 1m`
-newfs /dev/md${n} >/dev/null
-mount /dev/md${n} ${n0}
+n=`mdconfig -a -n -t malloc -s 1m` || exit
+newfs /dev/md${n} >/dev/null || exit
+mount /dev/md${n} ${n0} || exit
 expect 0 create ${n0}/${n1} 0644
 expect 0 chown ${n0}/${n1} 65534 65534
 expect 65534,65534 stat ${n0}/${n1} uid,gid
@@ -28,5 +28,5 @@ expect 0 chown ${n0}/${n1} 65533 65533
 expect 65533,65533 stat ${n0}/${n1} uid,gid
 expect 0 unlink ${n0}/${n1}
 umount /dev/md${n}
-mdconfig -d -u ${n}
+mdconfig -d -u ${n} || exit
 expect 0 rmdir ${n0}

Modified: stable/10/contrib/pjdfstest/tests/ftruncate/00.t
==============================================================================
--- head/contrib/pjdfstest/tests/ftruncate/00.t	Wed Sep 24 07:00:35 2014	(r272057)
+++ stable/10/contrib/pjdfstest/tests/ftruncate/00.t	Fri Dec  5 11:44:18 2014	(r275504)
@@ -6,7 +6,7 @@ desc="ftruncate descrease/increase file 
 dir=`dirname $0`
 . ${dir}/../misc.sh
 
-echo "1..21"
+echo "1..26"
 
 n0=`namegen`
 n1=`namegen`

Modified: stable/10/contrib/pjdfstest/tests/ftruncate/10.t
==============================================================================
--- head/contrib/pjdfstest/tests/ftruncate/10.t	Wed Sep 24 07:00:35 2014	(r272057)
+++ stable/10/contrib/pjdfstest/tests/ftruncate/10.t	Fri Dec  5 11:44:18 2014	(r275504)
@@ -14,9 +14,9 @@ n0=`namegen`
 n1=`namegen`
 
 expect 0 mkdir ${n0} 0755
-n=`mdconfig -a -n -t malloc -s 1m`
-newfs /dev/md${n} >/dev/null
-mount /dev/md${n} ${n0}
+n=`mdconfig -a -n -t malloc -s 1m` || exit
+newfs /dev/md${n} >/dev/null || exit
+mount /dev/md${n} ${n0} || exit
 expect 0 create ${n0}/${n1} 0644
 expect 0 truncate ${n0}/${n1} 123
 expect 123 stat ${n0}/${n1} size
@@ -28,5 +28,5 @@ expect 0 truncate ${n0}/${n1} 1234
 expect 1234 stat ${n0}/${n1} size
 expect 0 unlink ${n0}/${n1}
 umount /dev/md${n}
-mdconfig -d -u ${n}
+mdconfig -d -u ${n} || exit
 expect 0 rmdir ${n0}

Modified: stable/10/contrib/pjdfstest/tests/link/05.t
==============================================================================
--- head/contrib/pjdfstest/tests/link/05.t	Wed Sep 24 07:00:35 2014	(r272057)
+++ stable/10/contrib/pjdfstest/tests/link/05.t	Fri Dec  5 11:44:18 2014	(r275504)
@@ -15,9 +15,9 @@ n1=`namegen`
 n2=`namegen`
 
 expect 0 mkdir ${n0} 0755
-n=`mdconfig -a -n -t malloc -s 1m`
-newfs -i 1 /dev/md${n} >/dev/null
-mount /dev/md${n} ${n0}
+n=`mdconfig -a -n -t malloc -s 1m` || exit
+newfs -i 1 /dev/md${n} >/dev/null || exit
+mount /dev/md${n} ${n0} || exit
 expect 0 create ${n0}/${n1} 0644
 i=1
 while :; do
@@ -32,5 +32,5 @@ test_check $i -eq 32767
 expect EMLINK link ${n0}/${n1} ${n0}/${n2}
 
 umount /dev/md${n}
-mdconfig -d -u ${n}
+mdconfig -d -u ${n} || exit
 expect 0 rmdir ${n0}

Modified: stable/10/contrib/pjdfstest/tests/link/14.t
==============================================================================
--- head/contrib/pjdfstest/tests/link/14.t	Wed Sep 24 07:00:35 2014	(r272057)
+++ stable/10/contrib/pjdfstest/tests/link/14.t	Fri Dec  5 11:44:18 2014	(r275504)
@@ -15,9 +15,9 @@ n1=`namegen`
 n2=`namegen`
 
 expect 0 mkdir ${n0} 0755
-n=`mdconfig -a -n -t malloc -s 1m`
-newfs /dev/md${n} >/dev/null
-mount /dev/md${n} ${n0}
+n=`mdconfig -a -n -t malloc -s 1m` || exit
+newfs /dev/md${n} >/dev/null || exit
+mount /dev/md${n} ${n0} || exit
 expect 0 create ${n0}/${n1} 0644
 expect EXDEV link ${n0}/${n1} ${n2}
 expect 0 unlink ${n0}/${n1}
@@ -25,5 +25,5 @@ expect 0 create ${n1} 0644
 expect EXDEV link ${n1} ${n0}/${n2}
 expect 0 unlink ${n1}
 umount /dev/md${n}
-mdconfig -d -u ${n}
+mdconfig -d -u ${n} || exit
 expect 0 rmdir ${n0}

Modified: stable/10/contrib/pjdfstest/tests/link/15.t
==============================================================================
--- head/contrib/pjdfstest/tests/link/15.t	Wed Sep 24 07:00:35 2014	(r272057)
+++ stable/10/contrib/pjdfstest/tests/link/15.t	Fri Dec  5 11:44:18 2014	(r275504)
@@ -15,9 +15,9 @@ n1=`namegen`
 n2=`namegen`
 
 expect 0 mkdir ${n0} 0755
-n=`mdconfig -a -n -t malloc -s 256k`
-newfs /dev/md${n} >/dev/null
-mount /dev/md${n} ${n0}
+n=`mdconfig -a -n -t malloc -s 512k` || exit
+newfs /dev/md${n} >/dev/null || exit
+mount /dev/md${n} ${n0} || exit
 expect 0 create ${n0}/${n1} 0644
 i=0
 while :; do
@@ -29,5 +29,5 @@ while :; do
 done
 expect ENOSPC link ${n0}/${n1} ${n0}/${n2}
 umount /dev/md${n}
-mdconfig -d -u ${n}
+mdconfig -d -u ${n} || exit
 expect 0 rmdir ${n0}

Modified: stable/10/contrib/pjdfstest/tests/link/16.t
==============================================================================
--- head/contrib/pjdfstest/tests/link/16.t	Wed Sep 24 07:00:35 2014	(r272057)
+++ stable/10/contrib/pjdfstest/tests/link/16.t	Fri Dec  5 11:44:18 2014	(r275504)
@@ -15,9 +15,9 @@ n1=`namegen`
 n2=`namegen`
 
 expect 0 mkdir ${n0} 0755
-n=`mdconfig -a -n -t malloc -s 1m`
-newfs /dev/md${n} >/dev/null
-mount /dev/md${n} ${n0}
+n=`mdconfig -a -n -t malloc -s 1m` || exit
+newfs /dev/md${n} >/dev/null || exit
+mount /dev/md${n} ${n0} || exit
 expect 0 create ${n0}/${n1} 0644
 
 expect 0 link ${n0}/${n1} ${n0}/${n2}
@@ -30,5 +30,5 @@ expect 0 unlink ${n0}/${n2}
 
 expect 0 unlink ${n0}/${n1}
 umount /dev/md${n}
-mdconfig -d -u ${n}
+mdconfig -d -u ${n} || exit
 expect 0 rmdir ${n0}

Modified: stable/10/contrib/pjdfstest/tests/mkdir/09.t
==============================================================================
--- head/contrib/pjdfstest/tests/mkdir/09.t	Wed Sep 24 07:00:35 2014	(r272057)
+++ stable/10/contrib/pjdfstest/tests/mkdir/09.t	Fri Dec  5 11:44:18 2014	(r275504)
@@ -14,9 +14,9 @@ n0=`namegen`
 n1=`namegen`
 
 expect 0 mkdir ${n0} 0755
-n=`mdconfig -a -n -t malloc -s 1m`
-newfs /dev/md${n} >/dev/null
-mount /dev/md${n} ${n0}
+n=`mdconfig -a -n -t malloc -s 1m` || exit
+newfs /dev/md${n} >/dev/null || exit
+mount /dev/md${n} ${n0} || exit
 expect 0 mkdir ${n0}/${n1} 0755
 expect 0 rmdir ${n0}/${n1}
 mount -ur /dev/md${n}
@@ -25,5 +25,5 @@ mount -uw /dev/md${n}
 expect 0 mkdir ${n0}/${n1} 0755
 expect 0 rmdir ${n0}/${n1}
 umount /dev/md${n}
-mdconfig -d -u ${n}
+mdconfig -d -u ${n} || exit
 expect 0 rmdir ${n0}

Modified: stable/10/contrib/pjdfstest/tests/mkdir/11.t
==============================================================================
--- head/contrib/pjdfstest/tests/mkdir/11.t	Wed Sep 24 07:00:35 2014	(r272057)
+++ stable/10/contrib/pjdfstest/tests/mkdir/11.t	Fri Dec  5 11:44:18 2014	(r275504)
@@ -14,9 +14,9 @@ n0=`namegen`
 n1=`namegen`
 
 expect 0 mkdir ${n0} 0755
-n=`mdconfig -a -n -t malloc -s 256k`
-newfs /dev/md${n} >/dev/null
-mount /dev/md${n} ${n0}
+n=`mdconfig -a -n -t malloc -s 512k` || exit
+newfs /dev/md${n} >/dev/null || exit
+mount /dev/md${n} ${n0} || exit
 i=0
 while :; do
 	mkdir ${n0}/${i} >/dev/null 2>&1
@@ -27,5 +27,5 @@ while :; do
 done
 expect ENOSPC mkdir ${n0}/${n1} 0755
 umount /dev/md${n}
-mdconfig -d -u ${n}
+mdconfig -d -u ${n} || exit
 expect 0 rmdir ${n0}

Modified: stable/10/contrib/pjdfstest/tests/mkfifo/08.t
==============================================================================
--- head/contrib/pjdfstest/tests/mkfifo/08.t	Wed Sep 24 07:00:35 2014	(r272057)
+++ stable/10/contrib/pjdfstest/tests/mkfifo/08.t	Fri Dec  5 11:44:18 2014	(r275504)
@@ -14,9 +14,9 @@ n0=`namegen`
 n1=`namegen`
 
 expect 0 mkdir ${n0} 0755
-n=`mdconfig -a -n -t malloc -s 1m`
-newfs /dev/md${n} >/dev/null
-mount /dev/md${n} ${n0}
+n=`mdconfig -a -n -t malloc -s 1m` || exit
+newfs /dev/md${n} >/dev/null || exit
+mount /dev/md${n} ${n0} || exit
 expect 0 mkfifo ${n0}/${n1} 0644
 expect 0 unlink ${n0}/${n1}
 mount -ur /dev/md${n}
@@ -25,5 +25,5 @@ mount -uw /dev/md${n}
 expect 0 mkfifo ${n0}/${n1} 0644
 expect 0 unlink ${n0}/${n1}
 umount /dev/md${n}
-mdconfig -d -u ${n}
+mdconfig -d -u ${n} || exit
 expect 0 rmdir ${n0}

Modified: stable/10/contrib/pjdfstest/tests/mkfifo/11.t
==============================================================================
--- head/contrib/pjdfstest/tests/mkfifo/11.t	Wed Sep 24 07:00:35 2014	(r272057)
+++ stable/10/contrib/pjdfstest/tests/mkfifo/11.t	Fri Dec  5 11:44:18 2014	(r275504)
@@ -14,9 +14,9 @@ n0=`namegen`
 n1=`namegen`
 
 expect 0 mkdir ${n0} 0755
-n=`mdconfig -a -n -t malloc -s 256k`
-newfs /dev/md${n} >/dev/null
-mount /dev/md${n} ${n0}
+n=`mdconfig -a -n -t malloc -s 512k` || exit
+newfs /dev/md${n} >/dev/null || exit
+mount /dev/md${n} ${n0} || exit
 i=0
 while :; do
 	mkfifo ${n0}/${i} >/dev/null 2>&1
@@ -27,5 +27,5 @@ while :; do
 done
 expect ENOSPC mkfifo ${n0}/${n1} 0644
 umount /dev/md${n}
-mdconfig -d -u ${n}
+mdconfig -d -u ${n} || exit
 expect 0 rmdir ${n0}

Modified: stable/10/contrib/pjdfstest/tests/open/14.t
==============================================================================
--- head/contrib/pjdfstest/tests/open/14.t	Wed Sep 24 07:00:35 2014	(r272057)
+++ stable/10/contrib/pjdfstest/tests/open/14.t	Fri Dec  5 11:44:18 2014	(r275504)
@@ -14,9 +14,9 @@ n0=`namegen`
 n1=`namegen`
 
 expect 0 mkdir ${n0} 0755
-n=`mdconfig -a -n -t malloc -s 1m`
-newfs /dev/md${n} >/dev/null
-mount /dev/md${n} ${n0}
+n=`mdconfig -a -n -t malloc -s 1m` || exit
+newfs /dev/md${n} >/dev/null || exit
+mount /dev/md${n} ${n0} || exit
 expect 0 create ${n0}/${n1} 0644
 expect 0 open ${n0}/${n1} O_WRONLY
 expect 0 open ${n0}/${n1} O_RDWR
@@ -28,5 +28,5 @@ expect EROFS open ${n0}/${n1} O_RDONLY,O
 mount -uw /dev/md${n}
 expect 0 unlink ${n0}/${n1}
 umount /dev/md${n}
-mdconfig -d -u ${n}
+mdconfig -d -u ${n} || exit
 expect 0 rmdir ${n0}

Modified: stable/10/contrib/pjdfstest/tests/open/15.t
==============================================================================
--- head/contrib/pjdfstest/tests/open/15.t	Wed Sep 24 07:00:35 2014	(r272057)
+++ stable/10/contrib/pjdfstest/tests/open/15.t	Fri Dec  5 11:44:18 2014	(r275504)
@@ -14,14 +14,14 @@ n0=`namegen`
 n1=`namegen`
 
 expect 0 mkdir ${n0} 0755
-n=`mdconfig -a -n -t malloc -s 1m`
-newfs /dev/md${n} >/dev/null
-mount /dev/md${n} ${n0}
+n=`mdconfig -a -n -t malloc -s 1m` || exit
+newfs /dev/md${n} >/dev/null || exit
+mount /dev/md${n} ${n0} || exit
 expect 0 open ${n0}/${n1} O_RDONLY,O_CREAT 0644
 expect 0 unlink ${n0}/${n1}
 mount -ur /dev/md${n}
 expect EROFS open ${n0}/${n1} O_RDONLY,O_CREAT 0644
 mount -uw /dev/md${n}
 umount /dev/md${n}
-mdconfig -d -u ${n}
+mdconfig -d -u ${n} || exit
 expect 0 rmdir ${n0}

Modified: stable/10/contrib/pjdfstest/tests/open/16.t
==============================================================================
--- head/contrib/pjdfstest/tests/open/16.t	Wed Sep 24 07:00:35 2014	(r272057)
+++ stable/10/contrib/pjdfstest/tests/open/16.t	Fri Dec  5 11:44:18 2014	(r275504)
@@ -1,19 +1,27 @@
 #!/bin/sh
 # $FreeBSD: head/tools/regression/pjdfstest/tests/open/16.t 219621 2011-03-13 19:35:13Z pjd $
 
-desc="open returns ELOOP when O_NOFOLLOW was specified and the target is a symbolic link"
-
 dir=`dirname $0`
 . ${dir}/../misc.sh
 
+case "${os}" in
+Darwin|Linux)
+	error=ELOOP
+	;;
+*)
+	error=EMLINK
+	;;
+esac
+desc="open returns $error when O_NOFOLLOW was specified and the target is a symbolic link"
+
 echo "1..6"
 
 n0=`namegen`
 n1=`namegen`
 
 expect 0 symlink ${n0} ${n1}
-expect ELOOP open ${n1} O_RDONLY,O_CREAT,O_NOFOLLOW 0644
-expect ELOOP open ${n1} O_RDONLY,O_NOFOLLOW
-expect ELOOP open ${n1} O_WRONLY,O_NOFOLLOW
-expect ELOOP open ${n1} O_RDWR,O_NOFOLLOW
+expect $error open ${n1} O_RDONLY,O_CREAT,O_NOFOLLOW 0644
+expect $error open ${n1} O_RDONLY,O_NOFOLLOW
+expect $error open ${n1} O_WRONLY,O_NOFOLLOW
+expect $error open ${n1} O_RDWR,O_NOFOLLOW
 expect 0 unlink ${n1}

Modified: stable/10/contrib/pjdfstest/tests/open/19.t
==============================================================================
--- head/contrib/pjdfstest/tests/open/19.t	Wed Sep 24 07:00:35 2014	(r272057)
+++ stable/10/contrib/pjdfstest/tests/open/19.t	Fri Dec  5 11:44:18 2014	(r275504)
@@ -14,9 +14,9 @@ n0=`namegen`
 n1=`namegen`
 
 expect 0 mkdir ${n0} 0755
-n=`mdconfig -a -n -t malloc -s 256k`
-newfs /dev/md${n} >/dev/null
-mount /dev/md${n} ${n0}
+n=`mdconfig -a -n -t malloc -s 512k` || exit
+newfs /dev/md${n} >/dev/null || exit
+mount /dev/md${n} ${n0} || exit
 i=0
 while :; do
 	touch ${n0}/${i} >/dev/null 2>&1
@@ -27,5 +27,5 @@ while :; do
 done
 expect ENOSPC open ${n0}/${i} O_RDONLY,O_CREAT 0644
 umount /dev/md${n}
-mdconfig -d -u ${n}
+mdconfig -d -u ${n} || exit
 expect 0 rmdir ${n0}

Modified: stable/10/contrib/pjdfstest/tests/rename/15.t
==============================================================================
--- head/contrib/pjdfstest/tests/rename/15.t	Wed Sep 24 07:00:35 2014	(r272057)
+++ stable/10/contrib/pjdfstest/tests/rename/15.t	Fri Dec  5 11:44:18 2014	(r275504)
@@ -15,9 +15,9 @@ n1=`namegen`
 n2=`namegen`
 
 expect 0 mkdir ${n0} 0755
-n=`mdconfig -a -n -t malloc -s 1m`
-newfs /dev/md${n} >/dev/null
-mount /dev/md${n} ${n0}
+n=`mdconfig -a -n -t malloc -s 1m` || exit
+newfs /dev/md${n} >/dev/null || exit
+mount /dev/md${n} ${n0} || exit
 
 for type in regular dir fifo block char socket symlink; do
 	create_file ${type} ${n0}/${n1}
@@ -30,5 +30,5 @@ for type in regular dir fifo block char 
 done
 
 umount /dev/md${n}
-mdconfig -d -u ${n}
+mdconfig -d -u ${n} || exit
 expect 0 rmdir ${n0}

Modified: stable/10/contrib/pjdfstest/tests/rename/16.t
==============================================================================
--- head/contrib/pjdfstest/tests/rename/16.t	Wed Sep 24 07:00:35 2014	(r272057)
+++ stable/10/contrib/pjdfstest/tests/rename/16.t	Fri Dec  5 11:44:18 2014	(r275504)
@@ -15,9 +15,9 @@ n1=`namegen`
 n2=`namegen`
 
 expect 0 mkdir ${n0} 0755
-n=`mdconfig -a -n -t malloc -s 1m`
-newfs /dev/md${n} >/dev/null
-mount /dev/md${n} ${n0}
+n=`mdconfig -a -n -t malloc -s 1m` || exit
+newfs /dev/md${n} >/dev/null || exit
+mount /dev/md${n} ${n0} || exit
 expect 0 create ${n0}/${n1} 0644
 mount -ur /dev/md${n}
 
@@ -28,5 +28,5 @@ expect EROFS rename ${n2} ${n0}/${n2}
 expect 0 unlink ${n2}
 
 umount /dev/md${n}
-mdconfig -d -u ${n}
+mdconfig -d -u ${n} || exit
 expect 0 rmdir ${n0}

Modified: stable/10/contrib/pjdfstest/tests/rmdir/13.t
==============================================================================
--- head/contrib/pjdfstest/tests/rmdir/13.t	Wed Sep 24 07:00:35 2014	(r272057)
+++ stable/10/contrib/pjdfstest/tests/rmdir/13.t	Fri Dec  5 11:44:18 2014	(r275504)
@@ -13,10 +13,10 @@ echo "1..3"
 n0=`namegen`
 
 expect 0 mkdir ${n0} 0755
-n=`mdconfig -a -n -t malloc -s 1m`
-newfs /dev/md${n} >/dev/null
-mount /dev/md${n} ${n0}
+n=`mdconfig -a -n -t malloc -s 1m` || exit
+newfs /dev/md${n} >/dev/null || exit
+mount /dev/md${n} ${n0} || exit
 expect EBUSY rmdir ${n0}
 umount /dev/md${n}
-mdconfig -d -u ${n}
+mdconfig -d -u ${n} || exit
 expect 0 rmdir ${n0}

Modified: stable/10/contrib/pjdfstest/tests/rmdir/14.t
==============================================================================
--- head/contrib/pjdfstest/tests/rmdir/14.t	Wed Sep 24 07:00:35 2014	(r272057)
+++ stable/10/contrib/pjdfstest/tests/rmdir/14.t	Fri Dec  5 11:44:18 2014	(r275504)
@@ -14,14 +14,14 @@ n0=`namegen`
 n1=`namegen`
 
 expect 0 mkdir ${n0} 0755
-n=`mdconfig -a -n -t malloc -s 1m`
-newfs /dev/md${n} >/dev/null
-mount /dev/md${n} ${n0}
+n=`mdconfig -a -n -t malloc -s 1m` || exit
+newfs /dev/md${n} >/dev/null || exit
+mount /dev/md${n} ${n0} || exit
 expect 0 mkdir ${n0}/${n1} 0755
 mount -ur /dev/md${n}
 expect EROFS rmdir ${n0}/${n1}
 mount -uw /dev/md${n}
 expect 0 rmdir ${n0}/${n1}
 umount /dev/md${n}
-mdconfig -d -u ${n}
+mdconfig -d -u ${n} || exit
 expect 0 rmdir ${n0}

Modified: stable/10/contrib/pjdfstest/tests/symlink/10.t
==============================================================================
--- head/contrib/pjdfstest/tests/symlink/10.t	Wed Sep 24 07:00:35 2014	(r272057)
+++ stable/10/contrib/pjdfstest/tests/symlink/10.t	Fri Dec  5 11:44:18 2014	(r275504)
@@ -15,9 +15,9 @@ n1=`namegen`
 n2=`namegen`
 
 expect 0 mkdir ${n0} 0755
-n=`mdconfig -a -n -t malloc -s 1m`
-newfs /dev/md${n} >/dev/null
-mount /dev/md${n} ${n0}
+n=`mdconfig -a -n -t malloc -s 1m` || exit
+newfs /dev/md${n} >/dev/null || exit
+mount /dev/md${n} ${n0} || exit
 
 expect 0 symlink test ${n0}/${n1}
 expect 0 unlink ${n0}/${n1}
@@ -28,5 +28,5 @@ expect 0 symlink test ${n0}/${n1}
 expect 0 unlink ${n0}/${n1}
 
 umount /dev/md${n}
-mdconfig -d -u ${n}
+mdconfig -d -u ${n} || exit
 expect 0 rmdir ${n0}

Modified: stable/10/contrib/pjdfstest/tests/symlink/11.t
==============================================================================
--- head/contrib/pjdfstest/tests/symlink/11.t	Wed Sep 24 07:00:35 2014	(r272057)
+++ stable/10/contrib/pjdfstest/tests/symlink/11.t	Fri Dec  5 11:44:18 2014	(r275504)
@@ -14,9 +14,9 @@ n0=`namegen`
 n1=`namegen`
 
 expect 0 mkdir ${n0} 0755
-n=`mdconfig -a -n -t malloc -s 256k`
-newfs /dev/md${n} >/dev/null
-mount /dev/md${n} ${n0}
+n=`mdconfig -a -n -t malloc -s 512k` || exit
+newfs /dev/md${n} >/dev/null || exit
+mount /dev/md${n} ${n0} || exit
 i=0
 while :; do
 	ln -s test ${n0}/${i} >/dev/null 2>&1
@@ -27,5 +27,5 @@ while :; do
 done
 expect ENOSPC symlink test ${n0}/${n1}
 umount /dev/md${n}
-mdconfig -d -u ${n}
+mdconfig -d -u ${n} || exit
 expect 0 rmdir ${n0}

Modified: stable/10/contrib/pjdfstest/tests/truncate/10.t
==============================================================================
--- head/contrib/pjdfstest/tests/truncate/10.t	Wed Sep 24 07:00:35 2014	(r272057)
+++ stable/10/contrib/pjdfstest/tests/truncate/10.t	Fri Dec  5 11:44:18 2014	(r275504)
@@ -14,9 +14,9 @@ n0=`namegen`
 n1=`namegen`
 
 expect 0 mkdir ${n0} 0755
-n=`mdconfig -a -n -t malloc -s 1m`
-newfs /dev/md${n} >/dev/null
-mount /dev/md${n} ${n0}
+n=`mdconfig -a -n -t malloc -s 1m` || exit
+newfs /dev/md${n} >/dev/null || exit
+mount /dev/md${n} ${n0} || exit
 expect 0 create ${n0}/${n1} 0644
 expect 0 truncate ${n0}/${n1} 123
 expect 123 stat ${n0}/${n1} size
@@ -28,5 +28,5 @@ expect 0 truncate ${n0}/${n1} 1234
 expect 1234 stat ${n0}/${n1} size
 expect 0 unlink ${n0}/${n1}
 umount /dev/md${n}
-mdconfig -d -u ${n}
+mdconfig -d -u ${n} || exit
 expect 0 rmdir ${n0}

Modified: stable/10/contrib/pjdfstest/tests/unlink/12.t
==============================================================================
--- head/contrib/pjdfstest/tests/unlink/12.t	Wed Sep 24 07:00:35 2014	(r272057)
+++ stable/10/contrib/pjdfstest/tests/unlink/12.t	Fri Dec  5 11:44:18 2014	(r275504)
@@ -14,14 +14,14 @@ n0=`namegen`
 n1=`namegen`
 
 expect 0 mkdir ${n0} 0755
-n=`mdconfig -a -n -t malloc -s 1m`
-newfs /dev/md${n} >/dev/null
-mount /dev/md${n} ${n0}
+n=`mdconfig -a -n -t malloc -s 1m` || exit
+newfs /dev/md${n} >/dev/null || exit
+mount /dev/md${n} ${n0} || exit
 expect 0 create ${n0}/${n1} 0644
 mount -ur /dev/md${n}
 expect EROFS unlink ${n0}/${n1}
 mount -uw /dev/md${n}
 expect 0 unlink ${n0}/${n1}
 umount /dev/md${n}
-mdconfig -d -u ${n}
+mdconfig -d -u ${n} || exit
 expect 0 rmdir ${n0}

Modified: stable/10/etc/mtree/BSD.tests.dist
==============================================================================
--- stable/10/etc/mtree/BSD.tests.dist	Fri Dec  5 10:23:18 2014	(r275503)
+++ stable/10/etc/mtree/BSD.tests.dist	Fri Dec  5 11:44:18 2014	(r275504)
@@ -17,6 +17,8 @@
         doc
             atf
             ..
+            pjdfstest
+            ..
         ..
     ..
     tests
@@ -131,6 +133,38 @@
             ..
             netinet
             ..
+            pjdfstest
+                chflags
+                ..
+                chmod
+                ..
+                chown
+                ..
+                ftruncate
+                ..
+                granular
+                ..
+                link
+                ..
+                mkdir
+                ..
+                mkfifo
+                ..
+                mknod
+                ..
+                open
+                ..
+                rename
+                ..
+                rmdir
+                ..
+                symlink
+                ..
+                truncate
+                ..
+                unlink
+                ..
+            ..
         ..
         usr.bin
             apply

Modified: stable/10/share/doc/Makefile
==============================================================================
--- stable/10/share/doc/Makefile	Fri Dec  5 10:23:18 2014	(r275503)
+++ stable/10/share/doc/Makefile	Fri Dec  5 11:44:18 2014	(r275504)
@@ -7,10 +7,12 @@ SUBDIR=	${_IPv6} \
 	${_atf} \
 	legal \
 	${_llvm} \
+	${_pjdfstest} \
 	${_roffdocs}
 
 .if ${MK_TESTS} != "no"
 _atf= atf
+_pjdfstest= pjdfstest
 .endif
 
 .if ${MK_CLANG} != "no"

Modified: stable/10/tests/sys/Makefile
==============================================================================
--- stable/10/tests/sys/Makefile	Fri Dec  5 10:23:18 2014	(r275503)
+++ stable/10/tests/sys/Makefile	Fri Dec  5 11:44:18 2014	(r275504)
@@ -2,8 +2,12 @@
 
 .include <bsd.own.mk>
 
+TESTSDIR= ${TESTSBASE}/sys
+
 TESTS_SUBDIRS+=		kern
 TESTS_SUBDIRS+=		netinet
-TESTSDIR= ${TESTSBASE}/sys
+
+# Items not integrated into kyua runs by default
+SUBDIR+=		pjdfstest
 
 .include <bsd.test.mk>

Modified: stable/10/tools/build/mk/OptionalObsoleteFiles.inc
==============================================================================
--- stable/10/tools/build/mk/OptionalObsoleteFiles.inc	Fri Dec  5 10:23:18 2014	(r275503)
+++ stable/10/tools/build/mk/OptionalObsoleteFiles.inc	Fri Dec  5 11:44:18 2014	(r275504)
@@ -4016,9 +4016,10 @@ OLD_FILES+=usr/share/sendmail/cf/sitecon
 OLD_FILES+=usr/share/sendmail/cf/siteconfig/uucp.ucbvax.m4
 .endif
 
-#.if ${MK_SHAREDOCS} == no
-# to be filled in
-#.endif
+.if ${MK_SHAREDOCS} == no
+OLD_FILES+=usr/share/doc/pjdfstest/README
+OLD_DIRS+=usr/share/doc/pjdfstest
+.endif
 
 #.if ${MK_SYSCONS} == no
 # to be filled in


More information about the svn-src-all mailing list