diff options
| author | Enji Cooper <ngie@FreeBSD.org> | 2017-06-28 08:48:09 +0000 |
|---|---|---|
| committer | Enji Cooper <ngie@FreeBSD.org> | 2017-06-28 08:48:09 +0000 |
| commit | a5b450a49bc66a4d95320117399db1432dab6872 (patch) | |
| tree | 39a39ec551b0e354cb0265a0b8c7f2b5ba521430 /tests/link | |
| parent | 9a56205fc912cc30c498cd8ab536eef96373b16f (diff) | |
Pull down pjdfstest 0.1vendor/pjdfstest/0.1vendor/pjdfstest
The summary of changes is as follows..
Generic changes::
- Added configure support [2].
- Check for lchmod filesystem support with create_file(..); for
testcases that require lchmod, skip the testcase -- otherwise
use chmod directly [1].
- Added Travis CI integration [2].
- Added utimensat testcases [1].
Linux support::
- Fixed Linux support to pass on later supported versions of
Fedora/Ubuntu [2].
- Conditionally enable posix_fallocate(2) support [2].
OSX support::
- Fixed compilation on OSX [2].
- Added partial OSX support (the test run isn't fully green yet)
[2].
Obtained from: https://github.com/pjd/pjdfstest/tree/0.1
Submitted by: asomers [1], ngie [2]
Notes
Notes:
svn path=/vendor/pjdfstest/dist/; revision=320447
svn path=/vendor/pjdfstest/0.1/; revision=320449; tag=vendor/pjdfstest/0.1
Diffstat (limited to 'tests/link')
| -rw-r--r-- | tests/link/00.t | 1 | ||||
| -rw-r--r-- | tests/link/01.t | 1 | ||||
| -rw-r--r-- | tests/link/02.t | 1 | ||||
| -rw-r--r-- | tests/link/03.t | 1 | ||||
| -rw-r--r-- | tests/link/04.t | 1 | ||||
| -rw-r--r-- | tests/link/05.t | 9 | ||||
| -rw-r--r-- | tests/link/06.t | 1 | ||||
| -rw-r--r-- | tests/link/07.t | 1 | ||||
| -rw-r--r-- | tests/link/08.t | 1 | ||||
| -rw-r--r-- | tests/link/09.t | 1 | ||||
| -rw-r--r-- | tests/link/10.t | 1 | ||||
| -rw-r--r-- | tests/link/11.t | 1 | ||||
| -rw-r--r-- | tests/link/12.t | 30 | ||||
| -rw-r--r-- | tests/link/13.t | 1 | ||||
| -rw-r--r-- | tests/link/14.t | 9 | ||||
| -rw-r--r-- | tests/link/15.t | 9 | ||||
| -rw-r--r-- | tests/link/16.t | 9 | ||||
| -rw-r--r-- | tests/link/17.t | 1 |
18 files changed, 43 insertions, 36 deletions
diff --git a/tests/link/00.t b/tests/link/00.t index 1bcb32ad17ac..940ffba63f2b 100644 --- a/tests/link/00.t +++ b/tests/link/00.t @@ -1,4 +1,5 @@ #!/bin/sh +# vim: filetype=sh noexpandtab ts=8 sw=8 # $FreeBSD: head/tools/regression/pjdfstest/tests/link/00.t 211352 2010-08-15 21:24:17Z pjd $ desc="link creates hardlinks" diff --git a/tests/link/01.t b/tests/link/01.t index fe05aeba7119..c3ddade58455 100644 --- a/tests/link/01.t +++ b/tests/link/01.t @@ -1,4 +1,5 @@ #!/bin/sh +# vim: filetype=sh noexpandtab ts=8 sw=8 # $FreeBSD: head/tools/regression/pjdfstest/tests/link/01.t 211474 2010-08-18 22:06:43Z pjd $ desc="link returns ENOTDIR if a component of either path prefix is not a directory" diff --git a/tests/link/02.t b/tests/link/02.t index ca3e092edf99..5ba8c50892bd 100644 --- a/tests/link/02.t +++ b/tests/link/02.t @@ -1,4 +1,5 @@ #!/bin/sh +# vim: filetype=sh noexpandtab ts=8 sw=8 # $FreeBSD: head/tools/regression/pjdfstest/tests/link/02.t 211352 2010-08-15 21:24:17Z pjd $ desc="link returns ENAMETOOLONG if a component of either pathname exceeded {NAME_MAX} characters" diff --git a/tests/link/03.t b/tests/link/03.t index 22f8e55e0cb3..9efc137aad6d 100644 --- a/tests/link/03.t +++ b/tests/link/03.t @@ -1,4 +1,5 @@ #!/bin/sh +# vim: filetype=sh noexpandtab ts=8 sw=8 # $FreeBSD: head/tools/regression/pjdfstest/tests/link/03.t 211352 2010-08-15 21:24:17Z pjd $ desc="link returns ENAMETOOLONG if an entire length of either path name exceeded {PATH_MAX} characters" diff --git a/tests/link/04.t b/tests/link/04.t index bb095396005e..615722c377ab 100644 --- a/tests/link/04.t +++ b/tests/link/04.t @@ -1,4 +1,5 @@ #!/bin/sh +# vim: filetype=sh noexpandtab ts=8 sw=8 # $FreeBSD: head/tools/regression/pjdfstest/tests/link/04.t 211352 2010-08-15 21:24:17Z pjd $ desc="link returns ENOENT if a component of either path prefix does not exist" diff --git a/tests/link/05.t b/tests/link/05.t index 7db93fd96c67..5a18c2103e1d 100644 --- a/tests/link/05.t +++ b/tests/link/05.t @@ -1,4 +1,5 @@ #!/bin/sh +# vim: filetype=sh noexpandtab ts=8 sw=8 # $FreeBSD: head/tools/regression/pjdfstest/tests/link/05.t 211352 2010-08-15 21:24:17Z pjd $ desc="link returns EMLINK if the link count of the file named by name1 would exceed 32767" @@ -15,9 +16,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 +33,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} diff --git a/tests/link/06.t b/tests/link/06.t index 73ab01e9ae15..04f5110a0ba0 100644 --- a/tests/link/06.t +++ b/tests/link/06.t @@ -1,4 +1,5 @@ #!/bin/sh +# vim: filetype=sh noexpandtab ts=8 sw=8 # $FreeBSD: head/tools/regression/pjdfstest/tests/link/06.t 211352 2010-08-15 21:24:17Z pjd $ desc="link returns EACCES when a component of either path prefix denies search permission" diff --git a/tests/link/07.t b/tests/link/07.t index 68495dd7c0b8..afe1b734c209 100644 --- a/tests/link/07.t +++ b/tests/link/07.t @@ -1,4 +1,5 @@ #!/bin/sh +# vim: filetype=sh noexpandtab ts=8 sw=8 # $FreeBSD: head/tools/regression/pjdfstest/tests/link/07.t 211352 2010-08-15 21:24:17Z pjd $ desc="link returns EACCES when the requested link requires writing in a directory with a mode that denies write permission" diff --git a/tests/link/08.t b/tests/link/08.t index f4599d50f01b..eed5a46c5eda 100644 --- a/tests/link/08.t +++ b/tests/link/08.t @@ -1,4 +1,5 @@ #!/bin/sh +# vim: filetype=sh noexpandtab ts=8 sw=8 # $FreeBSD: head/tools/regression/pjdfstest/tests/link/08.t 211352 2010-08-15 21:24:17Z pjd $ desc="link returns ELOOP if too many symbolic links were encountered in translating one of the pathnames" diff --git a/tests/link/09.t b/tests/link/09.t index 5f89655d3610..cef10d25f465 100644 --- a/tests/link/09.t +++ b/tests/link/09.t @@ -1,4 +1,5 @@ #!/bin/sh +# vim: filetype=sh noexpandtab ts=8 sw=8 # $FreeBSD: head/tools/regression/pjdfstest/tests/link/09.t 211352 2010-08-15 21:24:17Z pjd $ desc="link returns ENOENT if the source file does not exist" diff --git a/tests/link/10.t b/tests/link/10.t index 03ebbd25ffdb..1ff378b96335 100644 --- a/tests/link/10.t +++ b/tests/link/10.t @@ -1,4 +1,5 @@ #!/bin/sh +# vim: filetype=sh noexpandtab ts=8 sw=8 # $FreeBSD: head/tools/regression/pjdfstest/tests/link/10.t 211474 2010-08-18 22:06:43Z pjd $ desc="link returns EEXIST if the destination file does exist" diff --git a/tests/link/11.t b/tests/link/11.t index 260342cd1d31..aee270a4234a 100644 --- a/tests/link/11.t +++ b/tests/link/11.t @@ -1,4 +1,5 @@ #!/bin/sh +# vim: filetype=sh noexpandtab ts=8 sw=8 # $FreeBSD: head/tools/regression/pjdfstest/tests/link/11.t 211352 2010-08-15 21:24:17Z pjd $ desc="link returns EPERM if the source file is a directory" diff --git a/tests/link/12.t b/tests/link/12.t index a5408b656418..047360309d85 100644 --- a/tests/link/12.t +++ b/tests/link/12.t @@ -1,4 +1,5 @@ #!/bin/sh +# vim: filetype=sh noexpandtab ts=8 sw=8 # $FreeBSD: head/tools/regression/pjdfstest/tests/link/12.t 211352 2010-08-15 21:24:17Z pjd $ desc="link returns EPERM if the source file has its immutable or append-only flag set" @@ -10,7 +11,7 @@ require chflags case "${os}:${fs}" in FreeBSD:ZFS) - echo "1..27" + echo "1..28" ;; FreeBSD:UFS) echo "1..48" @@ -31,12 +32,9 @@ expect 0 unlink ${n1} expect 1 stat ${n0} nlink expect 0 chflags ${n0} SF_IMMUTABLE -todo FreeBSD:ZFS "Creating a hard link to a file protected by SF_IMMUTABLE should return EPERM." expect EPERM link ${n0} ${n1} -todo FreeBSD:ZFS "Creating a hard link to a file protected by SF_IMMUTABLE should return EPERM." expect 1 stat ${n0} nlink expect 0 chflags ${n0} none -todo FreeBSD:ZFS "Creating a hard link to a file protected by SF_IMMUTABLE should return EPERM." expect 0 link ${n0} ${n1} expect 2 stat ${n0} nlink expect 0 unlink ${n1} @@ -49,24 +47,16 @@ expect 0 chflags ${n0} none expect 0 unlink ${n1} expect 1 stat ${n0} nlink +expect 0 chflags ${n0} SF_APPEND +expect EPERM link ${n0} ${n1} +expect 0 chflags ${n0} none +expect 0 link ${n0} ${n1} +expect 2 stat ${n0} nlink +expect 0 unlink ${n1} +expect 1 stat ${n0} nlink + case "${os}:${fs}" in -FreeBSD:ZFS) - expect 0 chflags ${n0} SF_APPEND - expect 0 link ${n0} ${n1} - expect 2 stat ${n0} nlink - expect 0 chflags ${n0} none - expect 0 unlink ${n1} - expect 1 stat ${n0} nlink - ;; FreeBSD:UFS) - expect 0 chflags ${n0} SF_APPEND - expect EPERM link ${n0} ${n1} - expect 0 chflags ${n0} none - expect 0 link ${n0} ${n1} - expect 2 stat ${n0} nlink - expect 0 unlink ${n1} - expect 1 stat ${n0} nlink - expect 0 chflags ${n0} UF_IMMUTABLE expect EPERM link ${n0} ${n1} expect 0 chflags ${n0} none diff --git a/tests/link/13.t b/tests/link/13.t index 2da8621f23cc..437f65d781c2 100644 --- a/tests/link/13.t +++ b/tests/link/13.t @@ -1,4 +1,5 @@ #!/bin/sh +# vim: filetype=sh noexpandtab ts=8 sw=8 # $FreeBSD: head/tools/regression/pjdfstest/tests/link/13.t 211352 2010-08-15 21:24:17Z pjd $ desc="link returns EPERM if the parent directory of the destination file has its immutable flag set" diff --git a/tests/link/14.t b/tests/link/14.t index 3a05dc0d10bc..34038a0ef8bf 100644 --- a/tests/link/14.t +++ b/tests/link/14.t @@ -1,4 +1,5 @@ #!/bin/sh +# vim: filetype=sh noexpandtab ts=8 sw=8 # $FreeBSD: head/tools/regression/pjdfstest/tests/link/14.t 211352 2010-08-15 21:24:17Z pjd $ desc="link returns EXDEV if the source and the destination files are on different file systems" @@ -15,9 +16,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 +26,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} diff --git a/tests/link/15.t b/tests/link/15.t index 972176bed08f..cb41ad503370 100644 --- a/tests/link/15.t +++ b/tests/link/15.t @@ -1,4 +1,5 @@ #!/bin/sh +# vim: filetype=sh noexpandtab ts=8 sw=8 # $FreeBSD: head/tools/regression/pjdfstest/tests/link/15.t 211352 2010-08-15 21:24:17Z pjd $ desc="link returns ENOSPC if the directory in which the entry for the new link is being placed cannot be extended because there is no space left on the file system containing the directory" @@ -15,9 +16,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 +30,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} diff --git a/tests/link/16.t b/tests/link/16.t index 56485ec1bee9..52c80ae7c54b 100644 --- a/tests/link/16.t +++ b/tests/link/16.t @@ -1,4 +1,5 @@ #!/bin/sh +# vim: filetype=sh noexpandtab ts=8 sw=8 # $FreeBSD: head/tools/regression/pjdfstest/tests/link/16.t 211352 2010-08-15 21:24:17Z pjd $ desc="link returns EROFS if the requested link requires writing in a directory on a read-only file system" @@ -15,9 +16,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 +31,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} diff --git a/tests/link/17.t b/tests/link/17.t index 9b7e6fc68366..4630373daa05 100644 --- a/tests/link/17.t +++ b/tests/link/17.t @@ -1,4 +1,5 @@ #!/bin/sh +# vim: filetype=sh noexpandtab ts=8 sw=8 # $FreeBSD: head/tools/regression/pjdfstest/tests/link/17.t 211352 2010-08-15 21:24:17Z pjd $ desc="link returns EFAULT if one of the pathnames specified is outside the process's allocated address space" |
