Index: stable/11/contrib/netbsd-tests/fs/tmpfs/h_funcs.subr =================================================================== --- stable/11/contrib/netbsd-tests/fs/tmpfs/h_funcs.subr (revision 310187) +++ stable/11/contrib/netbsd-tests/fs/tmpfs/h_funcs.subr (revision 310188) @@ -1,96 +1,115 @@ #!/bin/sh # # $NetBSD: h_funcs.subr,v 1.5 2013/03/17 01:16:45 jmmv Exp $ # # Copyright (c) 2005, 2006, 2007 The NetBSD Foundation, Inc. # All rights reserved. # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions # are met: # 1. Redistributions of source code must retain the above copyright # notice, this list of conditions and the following disclaimer. # 2. Redistributions in binary form must reproduce the above copyright # notice, this list of conditions and the following disclaimer in the # documentation and/or other materials provided with the distribution. # # THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND CONTRIBUTORS # ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED # TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR # PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS # BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR # CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF # SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS # INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN # CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) # ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE # POSSIBILITY OF SUCH DAMAGE. # Mount_Point= # # test_mount [args] # # Mounts tmpfs over ${Mount_Point} and changes the current directory # to the mount point. Optional arguments may be passed to the # mount command. # test_mount() { require_fs tmpfs Mount_Point=$(pwd)/mntpt atf_check -s eq:0 -o empty -e empty mkdir "${Mount_Point}" echo "mount -t tmpfs ${*} tmpfs ${Mount_Point}" mount -t tmpfs "${@}" tmpfs "${Mount_Point}" 2>mounterr if [ "${?}" -ne 0 ]; then cat mounterr 1>&2 if grep 'Operation not supported' mounterr > /dev/null; then atf_skip "tmpfs not supported" fi atf_fail "Failed to mount a tmpfs file system" fi cd "${Mount_Point}" } # # test_unmount # # Unmounts the file system mounted by test_mount. # test_unmount() { + # Begin FreeBSD + _test_unmount + exit_code=$? + atf_check_equal "$exit_code" "0" + return $exit_code + # End FreeBSD cd - >/dev/null atf_check -s eq:0 -o empty -e empty umount ${Mount_Point} atf_check -s eq:0 -o empty -e empty rmdir ${Mount_Point} Mount_Point= } + +# Begin FreeBSD +_test_unmount() { + if [ -z "${Mount_Point}" -o ! -d "${Mount_Point}" ]; then + return 0 + fi + + cd - >/dev/null + umount ${Mount_Point} + rmdir ${Mount_Point} + Mount_Point= +} +# End FreeBSD # # kqueue_monitor expected_nevents file1 [.. fileN] # # Monitors the commands given through stdin (one per line) using # kqueue and stores the events raised in a log that can be later # verified with kqueue_check. # kqueue_monitor() { nev=${1}; shift echo "Running kqueue-monitored commands and expecting" \ "${nev} events" $(atf_get_srcdir)/h_tools kqueue ${*} >kqueue.log || \ atf_fail "Could not launch kqueue monitor" got=$(wc -l kqueue.log | awk '{ print $1 }') test ${got} -eq ${nev} || \ atf_fail "Got ${got} events but expected ${nev}" } # # kqueue_check file event # # Checks if kqueue raised the given event when monitoring the # given file. # kqueue_check() { echo "Checking if ${1} received ${2}" grep "^${1} - ${2}$" kqueue.log >/dev/null || \ atf_fail "${1} did not receive ${2}" } Index: stable/11/contrib/netbsd-tests/fs/tmpfs/t_link.sh =================================================================== --- stable/11/contrib/netbsd-tests/fs/tmpfs/t_link.sh (revision 310187) +++ stable/11/contrib/netbsd-tests/fs/tmpfs/t_link.sh (revision 310188) @@ -1,144 +1,144 @@ # $NetBSD: t_link.sh,v 1.5 2010/11/07 17:51:18 jmmv Exp $ # # Copyright (c) 2005, 2006, 2007, 2008 The NetBSD Foundation, Inc. # All rights reserved. # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions # are met: # 1. Redistributions of source code must retain the above copyright # notice, this list of conditions and the following disclaimer. # 2. Redistributions in binary form must reproduce the above copyright # notice, this list of conditions and the following disclaimer in the # documentation and/or other materials provided with the distribution. # # THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND CONTRIBUTORS # ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED # TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR # PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS # BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR # CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF # SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS # INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN # CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) # ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE # POSSIBILITY OF SUCH DAMAGE. # # # Verifies that the link operation works. # atf_test_case basic basic_head() { atf_set "descr" "Verifies that the link operation works on files" \ "at the top directory" atf_set "require.user" "root" } basic_body() { test_mount atf_check -s eq:0 -o empty -e empty touch a atf_check -s eq:0 -o empty -e empty touch z eval $(stat -s a | sed -e 's|st_|sta_|g') eval $(stat -s z | sed -e 's|st_|stz_|g') test ${sta_ino} != ${stz_ino} || \ atf_fail "Node numbers are not different" test ${sta_nlink} -eq 1 || atf_fail "Number of links is incorrect" atf_check -s eq:0 -o empty -e empty ln a b echo "Checking if link count is correct after links are created" eval $(stat -s a | sed -e 's|st_|sta_|g') eval $(stat -s b | sed -e 's|st_|stb_|g') test ${sta_ino} = ${stb_ino} || atf_fail "Node number changed" test ${sta_nlink} -eq 2 || atf_fail "Link count is incorrect" test ${stb_nlink} -eq 2 || atf_fail "Link count is incorrect" echo "Checking if link count is correct after links are deleted" atf_check -s eq:0 -o empty -e empty rm a eval $(stat -s b | sed -e 's|st_|stb_|g') test ${stb_nlink} -eq 1 || atf_fail "Link count is incorrect" atf_check -s eq:0 -o empty -e empty rm b test_unmount } atf_test_case subdirs subdirs_head() { atf_set "descr" "Verifies that the link operation works if used" \ "in subdirectories" atf_set "require.user" "root" } subdirs_body() { test_mount atf_check -s eq:0 -o empty -e empty touch a atf_check -s eq:0 -o empty -e empty mkdir c atf_check -s eq:0 -o empty -e empty ln a c/b echo "Checking if link count is correct after links are created" eval $(stat -s a | sed -e 's|st_|sta_|g') eval $(stat -s c/b | sed -e 's|st_|stb_|g') test ${sta_ino} = ${stb_ino} || atf_fail "Node number changed" test ${sta_nlink} -eq 2 || atf_fail "Link count is incorrect" test ${stb_nlink} -eq 2 || atf_fail "Link count is incorrect" echo "Checking if link count is correct after links are deleted" atf_check -s eq:0 -o empty -e empty rm a eval $(stat -s c/b | sed -e 's|st_|stb_|g') test ${stb_nlink} -eq 1 || atf_fail "Link count is incorrect" atf_check -s eq:0 -o empty -e empty rm c/b atf_check -s eq:0 -o empty -e empty rmdir c test_unmount } # Begin FreeBSD if true; then atf_test_case kqueue cleanup kqueue_cleanup() { - Mount_Point=$(pwd)/mntpt test_unmount || : + Mount_Point=$(pwd)/mntpt _test_unmount || : } else # End FreeBSD atf_test_case kqueue # Begin FreeBSD fi # End FreeBSD kqueue_head() { atf_set "descr" "Verifies that creating a link raises the correct" \ "kqueue events" atf_set "require.user" "root" } kqueue_body() { test_mount # Begin FreeBSD atf_expect_fail "fails with: dir/b did not receive NOTE_LINK - bug 213662" # End FreeBSD atf_check -s eq:0 -o empty -e empty mkdir dir atf_check -s eq:0 -o empty -e empty touch dir/a echo 'ln dir/a dir/b' | kqueue_monitor 2 dir dir/a kqueue_check dir/a NOTE_LINK kqueue_check dir NOTE_WRITE echo 'rm dir/a' | kqueue_monitor 2 dir dir/b # XXX According to the (short) kqueue(2) documentation, the following # should raise a NOTE_LINK but FFS raises a NOTE_DELETE... kqueue_check dir/b NOTE_LINK kqueue_check dir NOTE_WRITE atf_check -s eq:0 -o empty -e empty rm dir/b atf_check -s eq:0 -o empty -e empty rmdir dir test_unmount } atf_init_test_cases() { . $(atf_get_srcdir)/../h_funcs.subr . $(atf_get_srcdir)/h_funcs.subr atf_add_test_case basic atf_add_test_case subdirs atf_add_test_case kqueue } Index: stable/11/contrib/netbsd-tests/fs/tmpfs/t_mount.sh =================================================================== --- stable/11/contrib/netbsd-tests/fs/tmpfs/t_mount.sh (revision 310187) +++ stable/11/contrib/netbsd-tests/fs/tmpfs/t_mount.sh (revision 310188) @@ -1,155 +1,156 @@ # $NetBSD: t_mount.sh,v 1.6 2010/11/07 17:51:18 jmmv Exp $ # # Copyright (c) 2005, 2006, 2007, 2008 The NetBSD Foundation, Inc. # All rights reserved. # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions # are met: # 1. Redistributions of source code must retain the above copyright # notice, this list of conditions and the following disclaimer. # 2. Redistributions in binary form must reproduce the above copyright # notice, this list of conditions and the following disclaimer in the # documentation and/or other materials provided with the distribution. # # THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND CONTRIBUTORS # ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED # TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR # PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS # BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR # CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF # SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS # INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN # CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) # ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE # POSSIBILITY OF SUCH DAMAGE. # # # Verifies that an execution of mount and umount works correctly without # causing errors and that the root node gets correct attributes. # Also verifies command line parsing from mount_tmpfs. # atf_test_case plain plain_head() { atf_set "descr" "Tests a mount and unmount without any options" atf_set "require.user" "root" } plain_body() { test_mount test_unmount } atf_test_case links links_head() { atf_set "descr" "Tests that the mount point has two hard links" atf_set "require.user" "root" } links_body() { test_mount eval $(stat -s ${Mount_Point}) [ ${st_nlink} = 2 ] || \ atf_fail "Root directory does not have two hard links" test_unmount } atf_test_case options options_head() { atf_set "descr" "Tests the read-only mount option" atf_set "require.user" "root" } options_body() { test_mount -o ro mount | grep ${Mount_Point} | grep -q read-only || \ atf_fail "read-only option (ro) does not work" test_unmount } atf_test_case attrs attrs_head() { atf_set "descr" "Tests that root directory attributes are set" \ "correctly" atf_set "require.user" "root" } attrs_body() { test_mount -o -u1000 -o -g100 -o -m755 eval $(stat -s ${Mount_Point}) [ ${st_uid} = 1000 ] || atf_fail "uid is incorrect" [ ${st_gid} = 100 ] || atf_fail "gid is incorrect" [ ${st_mode} = 040755 ] || atf_fail "mode is incorrect" test_unmount } atf_test_case negative negative_head() { atf_set "descr" "Tests that negative values passed to to -s are" \ "handled correctly" atf_set "require.user" "root" } negative_body() { mkdir tmp test_mount -o -s-10 test_unmount } # Begin FreeBSD if true; then atf_test_case large cleanup large_cleanup() { - umount -f tmp 2>/dev/null + umount -f tmp 2>/dev/null || : + Mount_Point=$(pwd)/mnt _test_unmount || : } else # End FreeBSD atf_test_case large # Begin FreeBSD fi # End FreeBSD large_head() { atf_set "descr" "Tests that extremely long values passed to -s" \ "are handled correctly" atf_set "require.user" "root" } large_body() { test_mount -o -s9223372036854775807 test_unmount # Begin FreeBSD atf_expect_fail "-o -s succeeds unexpectedly on FreeBSD - bug 212862" # End FreeBSD mkdir tmp atf_check -s eq:1 -o empty -e ignore \ mount -t tmpfs -o -s9223372036854775808 tmpfs tmp atf_check -s eq:1 -o empty -e ignore \ mount -t tmpfs -o -s9223372036854775808g tmpfs tmp rmdir tmp } atf_test_case mntpt mntpt_head() { atf_set "descr" "Tests that the error messages printed when the" \ "mount point is invalid do not show the source" \ "unused parameter" } mntpt_body() { mount_tmpfs unused $(pwd)/mnt >out 2>&1 atf_check -s eq:1 -o empty -e empty grep unused out atf_check -s eq:0 -o ignore -e empty grep "$(pwd)/mnt" out mount_tmpfs unused mnt >out 2>&1 atf_check -s eq:1 -o empty -e empty grep unused out atf_check -s eq:0 -o ignore -e empty grep mnt out } atf_init_test_cases() { . $(atf_get_srcdir)/../h_funcs.subr . $(atf_get_srcdir)/h_funcs.subr atf_add_test_case plain atf_add_test_case options atf_add_test_case attrs atf_add_test_case negative atf_add_test_case large atf_add_test_case mntpt } Index: stable/11/contrib/netbsd-tests/fs/tmpfs/t_remove.sh =================================================================== --- stable/11/contrib/netbsd-tests/fs/tmpfs/t_remove.sh (revision 310187) +++ stable/11/contrib/netbsd-tests/fs/tmpfs/t_remove.sh (revision 310188) @@ -1,125 +1,125 @@ # $NetBSD: t_remove.sh,v 1.5 2010/11/07 17:51:18 jmmv Exp $ # # Copyright (c) 2005, 2006, 2007, 2008 The NetBSD Foundation, Inc. # All rights reserved. # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions # are met: # 1. Redistributions of source code must retain the above copyright # notice, this list of conditions and the following disclaimer. # 2. Redistributions in binary form must reproduce the above copyright # notice, this list of conditions and the following disclaimer in the # documentation and/or other materials provided with the distribution. # # THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND CONTRIBUTORS # ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED # TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR # PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS # BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR # CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF # SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS # INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN # CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) # ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE # POSSIBILITY OF SUCH DAMAGE. # # # Verifies that the remove operation works. # atf_test_case single single_head() { atf_set "descr" "Checks that file removal works" atf_set "require.user" "root" } single_body() { test_mount atf_check -s eq:1 -o empty -e empty test -f a atf_check -s eq:0 -o empty -e empty touch a atf_check -s eq:0 -o empty -e empty test -f a atf_check -s eq:0 -o empty -e empty rm a atf_check -s eq:1 -o empty -e empty test -f a test_unmount } # Begin FreeBSD if true; then atf_test_case uchg cleanup uchg_cleanup() { - Mount_Point=$(pwd)/mntpt test_unmount || : + Mount_Point=$(pwd)/mntpt _test_unmount } else # End FreeBSD atf_test_case uchg # Begin FreeBSD fi # End FreeBSD uchg_head() { atf_set "descr" "Checks that files with the uchg flag set cannot" \ "be removed" atf_set "require.user" "root" } uchg_body() { # Begin FreeBSD atf_expect_fail "this fails on FreeBSD with root - bug 212861" # End FreeBSD test_mount atf_check -s eq:0 -o empty -e empty touch a atf_check -s eq:0 -o empty -e empty chflags uchg a atf_check -s eq:1 -o empty -e ignore rm -f a atf_check -s eq:0 -o empty -e empty chflags nouchg a atf_check -s eq:0 -o empty -e empty rm a atf_check -s eq:1 -o empty -e empty test -f a test_unmount } atf_test_case dot dot_head() { atf_set "descr" "Checks that '.' cannot be removed" atf_set "require.user" "root" } dot_body() { test_mount atf_check -s eq:0 -o empty -e empty mkdir a atf_check -s eq:1 -o empty -e ignore unlink a/. atf_check -s eq:0 -o empty -e empty rmdir a test_unmount } atf_test_case kqueue kqueue_head() { atf_set "descr" "Removes a file and checks the kqueue events" \ "raised" atf_set "require.user" "root" } kqueue_body() { test_mount atf_check -s eq:0 -o empty -e empty mkdir dir atf_check -s eq:0 -o empty -e empty touch dir/a echo 'rm dir/a' | kqueue_monitor 2 dir dir/a kqueue_check dir/a NOTE_DELETE kqueue_check dir NOTE_WRITE atf_check -s eq:0 -o empty -e empty rmdir dir test_unmount } atf_init_test_cases() { . $(atf_get_srcdir)/../h_funcs.subr . $(atf_get_srcdir)/h_funcs.subr atf_add_test_case single atf_add_test_case uchg atf_add_test_case dot atf_add_test_case kqueue } Index: stable/11/contrib/netbsd-tests/fs/tmpfs/t_vnd.sh =================================================================== --- stable/11/contrib/netbsd-tests/fs/tmpfs/t_vnd.sh (revision 310187) +++ stable/11/contrib/netbsd-tests/fs/tmpfs/t_vnd.sh (revision 310188) @@ -1,103 +1,103 @@ # $NetBSD: t_vnd.sh,v 1.9 2016/07/29 05:23:24 pgoyette Exp $ # # Copyright (c) 2006, 2007, 2008 The NetBSD Foundation, Inc. # All rights reserved. # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions # are met: # 1. Redistributions of source code must retain the above copyright # notice, this list of conditions and the following disclaimer. # 2. Redistributions in binary form must reproduce the above copyright # notice, this list of conditions and the following disclaimer in the # documentation and/or other materials provided with the distribution. # # THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND CONTRIBUTORS # ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED # TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR # PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS # BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR # CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF # SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS # INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN # CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) # ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE # POSSIBILITY OF SUCH DAMAGE. # # # Verifies that vnd works with files stored in tmpfs. # atf_test_case basic cleanup basic_head() { atf_set "descr" "Verifies that vnd works with files stored in tmpfs" atf_set "require.user" "root" } basic_body() { test_mount atf_check -s eq:0 -o ignore -e ignore \ dd if=/dev/zero of=disk.img bs=1m count=10 # Begin FreeBSD if true; then atf_check -s eq:0 -o empty -e empty mkdir mnt atf_check -s eq:0 -o empty -e empty mdmfs -F disk.img md3 mnt else # End FreeBSD atf_check -s eq:0 -o empty -e empty vndconfig /dev/vnd3 disk.img atf_check -s eq:0 -o ignore -e ignore newfs /dev/rvnd3a atf_check -s eq:0 -o empty -e empty mkdir mnt atf_check -s eq:0 -o empty -e empty mount /dev/vnd3a mnt # Begin FreeBSD fi # End FreeBSD echo "Creating test files" for f in $(jot -w %u 100 | uniq); do jot 1000 >mnt/${f} || atf_fail "Failed to create file ${f}" done echo "Verifying created files" for f in $(jot -w %u 100 | uniq); do [ $(md5 mnt/${f} | cut -d ' ' -f 4) = \ 53d025127ae99ab79e8502aae2d9bea6 ] || \ atf_fail "Invalid checksum for file ${f}" done atf_check -s eq:0 -o empty -e empty umount mnt # Begin FreeBSD if true; then atf_check -s eq:0 -o empty -e empty mdconfig -d -u 3 else # End FreeBSD atf_check -s eq:0 -o empty -e empty vndconfig -u /dev/vnd3 # Begin FreeBSD fi # End FreeBSD test_unmount touch done } basic_cleanup() { if [ ! -f done ]; then umount mnt 2>/dev/null 1>&2 # Begin FreeBSD if true; then - atf_check -s eq:0 -o empty -e empty mdconfig -d -u 3 + [ ! -c /dev/md3 ] || mdconfig -d -u 3 else # End FreeBSD vndconfig -u /dev/vnd3 2>/dev/null 1>&2 # Begin FreeBSD fi # End FreeBSD fi } atf_init_test_cases() { . $(atf_get_srcdir)/../h_funcs.subr . $(atf_get_srcdir)/h_funcs.subr atf_add_test_case basic } Index: stable/11 =================================================================== --- stable/11 (revision 310187) +++ stable/11 (revision 310188) Property changes on: stable/11 ___________________________________________________________________ Modified: svn:mergeinfo ## -0,0 +0,1 ## Merged /head:r309774,309778-309780