ZTS: Move dumpdev tests to sunos.run

Neither FreeBSD nor Linux support dumping to zvols.

DilOS still uses these tests, so the files are kept and the tests have
been relocated to sunos.run.

An `is_illumos` function was added to libtest.shlib to eliminate some
awkward platform checks.

A few functions that are not expected to be used outside of illumos
have been sanitized of extraneous FreeBSD adaptations.

Reviewed-by: Igor Kozhukhov <igor@dilos.org>
Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Ryan Moeller <ryan@ixsystems.com>
Closes #9794
This commit is contained in:
Ryan Moeller
2020-01-03 12:08:23 -05:00
committed by Brian Behlendorf
parent cc618d179e
commit d7164b27be
16 changed files with 94 additions and 117 deletions
+1 -1
View File
@@ -143,7 +143,7 @@ export SPA_MINDEVSIZE=$((64 * 1024 * 1024))
# For iscsi target support
export ISCSITGTFILE=/tmp/iscsitgt_file
export ISCSITGT_FMRI=svc:/system/iscsitgt:default
if ! is_linux && ! is_freebsd; then
if is_illumos; then
export AUTO_SNAP=$(svcs -a | grep auto-snapshot | grep online | awk \
'{print $3}')
fi
+12
View File
@@ -92,6 +92,18 @@ function is_linux
fi
}
# Determine if this is an illumos test system
#
# Return 0 if platform illumos, 1 if otherwise
function is_illumos
{
if [[ $(uname -o) == "illumos" ]]; then
return 0
else
return 1
fi
}
# Determine if this is a FreeBSD test system
#
# Return 0 if platform FreeBSD, 1 if otherwise