Changeset View
Changeset View
Standalone View
Standalone View
tests/sys/cddl/zfs/tests/utils_test/utils_test_test.sh
Show All 24 Lines | |||||
# Use is subject to license terms. | # Use is subject to license terms. | ||||
# | # | ||||
atf_test_case utils_test_001_pos cleanup | atf_test_case utils_test_001_pos cleanup | ||||
utils_test_001_pos_head() | utils_test_001_pos_head() | ||||
{ | { | ||||
atf_set "descr" "Ensure that the clri(1M) utility fails on a ZFS file system." | atf_set "descr" "Ensure that the clri(1M) utility fails on a ZFS file system." | ||||
atf_set "require.progs" clri | atf_set "require.progs" "ksh93 clri" | ||||
} | } | ||||
utils_test_001_pos_body() | utils_test_001_pos_body() | ||||
{ | { | ||||
. $(atf_get_srcdir)/../../include/default.cfg | . $(atf_get_srcdir)/../../include/default.cfg | ||||
. $(atf_get_srcdir)/utils_test.kshlib | . $(atf_get_srcdir)/utils_test.kshlib | ||||
. $(atf_get_srcdir)/utils_test.cfg | . $(atf_get_srcdir)/utils_test.cfg | ||||
verify_disk_count "$DISKS" 1 | verify_disk_count "$DISKS" 1 | ||||
Show All 9 Lines | utils_test_001_pos_cleanup() | ||||
ksh93 $(atf_get_srcdir)/cleanup.ksh || atf_fail "Cleanup failed" | ksh93 $(atf_get_srcdir)/cleanup.ksh || atf_fail "Cleanup failed" | ||||
} | } | ||||
atf_test_case utils_test_002_pos cleanup | atf_test_case utils_test_002_pos cleanup | ||||
utils_test_002_pos_head() | utils_test_002_pos_head() | ||||
{ | { | ||||
atf_set "descr" "Ensure that the labelit(1M) utility fails on a ZFS file system." | atf_set "descr" "Ensure that the labelit(1M) utility fails on a ZFS file system." | ||||
atf_set "require.progs" zfs labelit | atf_set "require.progs" "ksh93 zfs labelit" | ||||
} | } | ||||
utils_test_002_pos_body() | utils_test_002_pos_body() | ||||
{ | { | ||||
. $(atf_get_srcdir)/../../include/default.cfg | . $(atf_get_srcdir)/../../include/default.cfg | ||||
. $(atf_get_srcdir)/utils_test.kshlib | . $(atf_get_srcdir)/utils_test.kshlib | ||||
. $(atf_get_srcdir)/utils_test.cfg | . $(atf_get_srcdir)/utils_test.cfg | ||||
verify_disk_count "$DISKS" 1 | verify_disk_count "$DISKS" 1 | ||||
Show All 9 Lines | utils_test_002_pos_cleanup() | ||||
ksh93 $(atf_get_srcdir)/cleanup.ksh || atf_fail "Cleanup failed" | ksh93 $(atf_get_srcdir)/cleanup.ksh || atf_fail "Cleanup failed" | ||||
} | } | ||||
atf_test_case utils_test_003_pos cleanup | atf_test_case utils_test_003_pos cleanup | ||||
utils_test_003_pos_head() | utils_test_003_pos_head() | ||||
{ | { | ||||
atf_set "descr" "Ensure that the fsdb(1M) utility fails on a ZFS file system." | atf_set "descr" "Ensure that the fsdb(1M) utility fails on a ZFS file system." | ||||
atf_set "require.progs" fsdb | atf_set "require.progs" "ksh93 fsdb" | ||||
} | } | ||||
utils_test_003_pos_body() | utils_test_003_pos_body() | ||||
{ | { | ||||
. $(atf_get_srcdir)/../../include/default.cfg | . $(atf_get_srcdir)/../../include/default.cfg | ||||
. $(atf_get_srcdir)/utils_test.kshlib | . $(atf_get_srcdir)/utils_test.kshlib | ||||
. $(atf_get_srcdir)/utils_test.cfg | . $(atf_get_srcdir)/utils_test.cfg | ||||
verify_disk_count "$DISKS" 1 | verify_disk_count "$DISKS" 1 | ||||
Show All 9 Lines | utils_test_003_pos_cleanup() | ||||
ksh93 $(atf_get_srcdir)/cleanup.ksh || atf_fail "Cleanup failed" | ksh93 $(atf_get_srcdir)/cleanup.ksh || atf_fail "Cleanup failed" | ||||
} | } | ||||
atf_test_case utils_test_004_pos cleanup | atf_test_case utils_test_004_pos cleanup | ||||
utils_test_004_pos_head() | utils_test_004_pos_head() | ||||
{ | { | ||||
atf_set "descr" "Ensure that the quotaon(1M) utility fails on a ZFS file system." | atf_set "descr" "Ensure that the quotaon(1M) utility fails on a ZFS file system." | ||||
atf_set "require.progs" zfs quotaon | atf_set "require.progs" "ksh93 zfs quotaon" | ||||
} | } | ||||
utils_test_004_pos_body() | utils_test_004_pos_body() | ||||
{ | { | ||||
atf_expect_fail "FreeBSD's quotaon utility exits 0 even when you supply a nonexistent filesystem" | atf_expect_fail "FreeBSD's quotaon utility exits 0 even when you supply a nonexistent filesystem" | ||||
. $(atf_get_srcdir)/../../include/default.cfg | . $(atf_get_srcdir)/../../include/default.cfg | ||||
. $(atf_get_srcdir)/utils_test.kshlib | . $(atf_get_srcdir)/utils_test.kshlib | ||||
. $(atf_get_srcdir)/utils_test.cfg | . $(atf_get_srcdir)/utils_test.cfg | ||||
Show All 10 Lines | utils_test_004_pos_cleanup() | ||||
ksh93 $(atf_get_srcdir)/cleanup.ksh || atf_fail "Cleanup failed" | ksh93 $(atf_get_srcdir)/cleanup.ksh || atf_fail "Cleanup failed" | ||||
} | } | ||||
atf_test_case utils_test_005_pos cleanup | atf_test_case utils_test_005_pos cleanup | ||||
utils_test_005_pos_head() | utils_test_005_pos_head() | ||||
{ | { | ||||
atf_set "descr" "Ensure that the ff(1M) utility fails on a ZFS file system." | atf_set "descr" "Ensure that the ff(1M) utility fails on a ZFS file system." | ||||
atf_set "require.progs" ff | atf_set "require.progs" "ksh93 ff" | ||||
} | } | ||||
utils_test_005_pos_body() | utils_test_005_pos_body() | ||||
{ | { | ||||
. $(atf_get_srcdir)/../../include/default.cfg | . $(atf_get_srcdir)/../../include/default.cfg | ||||
. $(atf_get_srcdir)/utils_test.kshlib | . $(atf_get_srcdir)/utils_test.kshlib | ||||
. $(atf_get_srcdir)/utils_test.cfg | . $(atf_get_srcdir)/utils_test.cfg | ||||
verify_disk_count "$DISKS" 1 | verify_disk_count "$DISKS" 1 | ||||
Show All 9 Lines | utils_test_005_pos_cleanup() | ||||
ksh93 $(atf_get_srcdir)/cleanup.ksh || atf_fail "Cleanup failed" | ksh93 $(atf_get_srcdir)/cleanup.ksh || atf_fail "Cleanup failed" | ||||
} | } | ||||
atf_test_case utils_test_006_pos cleanup | atf_test_case utils_test_006_pos cleanup | ||||
utils_test_006_pos_head() | utils_test_006_pos_head() | ||||
{ | { | ||||
atf_set "descr" "Ensure that the fsirand(1M) utility fails on a ZFS file system." | atf_set "descr" "Ensure that the fsirand(1M) utility fails on a ZFS file system." | ||||
atf_set "require.progs" zfs fsirand | atf_set "require.progs" "ksh93 zfs fsirand" | ||||
} | } | ||||
utils_test_006_pos_body() | utils_test_006_pos_body() | ||||
{ | { | ||||
. $(atf_get_srcdir)/../../include/default.cfg | . $(atf_get_srcdir)/../../include/default.cfg | ||||
. $(atf_get_srcdir)/utils_test.kshlib | . $(atf_get_srcdir)/utils_test.kshlib | ||||
. $(atf_get_srcdir)/utils_test.cfg | . $(atf_get_srcdir)/utils_test.cfg | ||||
verify_disk_count "$DISKS" 1 | verify_disk_count "$DISKS" 1 | ||||
Show All 9 Lines | utils_test_006_pos_cleanup() | ||||
ksh93 $(atf_get_srcdir)/cleanup.ksh || atf_fail "Cleanup failed" | ksh93 $(atf_get_srcdir)/cleanup.ksh || atf_fail "Cleanup failed" | ||||
} | } | ||||
atf_test_case utils_test_007_pos cleanup | atf_test_case utils_test_007_pos cleanup | ||||
utils_test_007_pos_head() | utils_test_007_pos_head() | ||||
{ | { | ||||
atf_set "descr" "Ensure that the fstyp(1M) utility succeeds on a ZFS file system." | atf_set "descr" "Ensure that the fstyp(1M) utility succeeds on a ZFS file system." | ||||
atf_set "require.progs" zfs fstyp | atf_set "require.progs" "ksh93 zfs fstyp" | ||||
} | } | ||||
utils_test_007_pos_body() | utils_test_007_pos_body() | ||||
{ | { | ||||
. $(atf_get_srcdir)/../../include/default.cfg | . $(atf_get_srcdir)/../../include/default.cfg | ||||
. $(atf_get_srcdir)/utils_test.kshlib | . $(atf_get_srcdir)/utils_test.kshlib | ||||
. $(atf_get_srcdir)/utils_test.cfg | . $(atf_get_srcdir)/utils_test.cfg | ||||
verify_disk_count "$DISKS" 1 | verify_disk_count "$DISKS" 1 | ||||
Show All 9 Lines | utils_test_007_pos_cleanup() | ||||
ksh93 $(atf_get_srcdir)/cleanup.ksh || atf_fail "Cleanup failed" | ksh93 $(atf_get_srcdir)/cleanup.ksh || atf_fail "Cleanup failed" | ||||
} | } | ||||
atf_test_case utils_test_008_pos cleanup | atf_test_case utils_test_008_pos cleanup | ||||
utils_test_008_pos_head() | utils_test_008_pos_head() | ||||
{ | { | ||||
atf_set "descr" "Ensure that the ncheck(1M) utility fails on a ZFS file system." | atf_set "descr" "Ensure that the ncheck(1M) utility fails on a ZFS file system." | ||||
atf_set "require.progs" zfs ncheck | atf_set "require.progs" "ksh93 zfs ncheck" | ||||
} | } | ||||
utils_test_008_pos_body() | utils_test_008_pos_body() | ||||
{ | { | ||||
. $(atf_get_srcdir)/../../include/default.cfg | . $(atf_get_srcdir)/../../include/default.cfg | ||||
. $(atf_get_srcdir)/utils_test.kshlib | . $(atf_get_srcdir)/utils_test.kshlib | ||||
. $(atf_get_srcdir)/utils_test.cfg | . $(atf_get_srcdir)/utils_test.cfg | ||||
verify_disk_count "$DISKS" 1 | verify_disk_count "$DISKS" 1 | ||||
Show All 9 Lines | utils_test_008_pos_cleanup() | ||||
ksh93 $(atf_get_srcdir)/cleanup.ksh || atf_fail "Cleanup failed" | ksh93 $(atf_get_srcdir)/cleanup.ksh || atf_fail "Cleanup failed" | ||||
} | } | ||||
atf_test_case utils_test_009_pos cleanup | atf_test_case utils_test_009_pos cleanup | ||||
utils_test_009_pos_head() | utils_test_009_pos_head() | ||||
{ | { | ||||
atf_set "descr" "Ensure that the tunefs(1M) utility fails on a ZFS file system." | atf_set "descr" "Ensure that the tunefs(1M) utility fails on a ZFS file system." | ||||
atf_set "require.progs" tunefs | atf_set "require.progs" "ksh93 tunefs" | ||||
} | } | ||||
utils_test_009_pos_body() | utils_test_009_pos_body() | ||||
{ | { | ||||
. $(atf_get_srcdir)/../../include/default.cfg | . $(atf_get_srcdir)/../../include/default.cfg | ||||
. $(atf_get_srcdir)/utils_test.kshlib | . $(atf_get_srcdir)/utils_test.kshlib | ||||
. $(atf_get_srcdir)/utils_test.cfg | . $(atf_get_srcdir)/utils_test.cfg | ||||
verify_disk_count "$DISKS" 1 | verify_disk_count "$DISKS" 1 | ||||
Show All 26 Lines |