summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMarcel Telka <[email protected]>2016-09-22 15:36:32 +0200
committerBrian Behlendorf <[email protected]>2017-02-13 11:32:56 -0800
commit37bb2fc7dc794536dbdad0375557cdb48924519b (patch)
treeb9f4f2aec3d07cfc8ae56fbc557876a205c146d6
parent94cc33f017b45dfdc137672e8e6feddc5ff56a9e (diff)
OpenZFS 7398 - zfs test zfs_get_005_neg does not work as expected
Authored by: Marcel Telka <[email protected]> Reviewed by: Yuri Pankov <[email protected]> Reviewed by: John Kennedy <[email protected]> Approved by: Dan McDonald <[email protected]> Reviewed-by: Brian Behlendorf <[email protected]> Ported-by: George Melikov <[email protected]> OpenZFS-issue: https://www.illumos.org/issues/7398 OpenZFS-commit: https://github.com/openzfs/openzfs/commit/4220fdc Closes #5782
-rwxr-xr-xtests/zfs-tests/tests/functional/cli_root/zfs_get/zfs_get_005_neg.ksh9
1 files changed, 4 insertions, 5 deletions
diff --git a/tests/zfs-tests/tests/functional/cli_root/zfs_get/zfs_get_005_neg.ksh b/tests/zfs-tests/tests/functional/cli_root/zfs_get/zfs_get_005_neg.ksh
index bc4ca2a43..71c48376b 100755
--- a/tests/zfs-tests/tests/functional/cli_root/zfs_get/zfs_get_005_neg.ksh
+++ b/tests/zfs-tests/tests/functional/cli_root/zfs_get/zfs_get_005_neg.ksh
@@ -49,7 +49,7 @@ typeset v_props=(type used available creation volsize referenced compressratio \
typeset userquota_props=(userquota@root groupquota@root userused@root \
groupused@root)
-typeset val_pros=(-- "${v_props[@]}" "${userquota_props[@]}")
+typeset val_props=("${v_props[@]}" "${userquota_props[@]}")
set -f # Force shell does not parse '?' and '*' as the wildcard
typeset inval_opts=(P R h ? *)
typeset inval_props=(Type 0 ? * -on --on readonl time USED RATIO MOUNTED)
@@ -62,7 +62,6 @@ typeset -i prop_numb=12
val_opts_str=$(gen_option_str "${val_opts[*]}" "-" "" $opt_numb)
val_props_str=$(gen_option_str "${val_props[*]}" "" "," $prop_numb)
-val_props_str="$val_props_str -a -d"
inval_opts_str=$(gen_option_str "${inval_opts[*]}" "-" "" $opt_numb)
inval_props_str=$(gen_option_str "${inval_props[*]}" "" "," $prop_numb)
@@ -84,11 +83,11 @@ function test_options
for dst in ${dataset[@]}; do
for opt in $opts; do
for prop in $props; do
- $ZFS get $opt $prop $dst > /dev/null 2>&1
+ $ZFS get $opt -- $prop $dst > /dev/null 2>&1
ret=$?
if [[ $ret == 0 ]]; then
- log_fail "$ZFS get $opt $prop $dst " \
- "unexpectedly succeeded."
+ log_fail "$ZFS get $opt -- $prop " \
+ "$dst unexpectedly succeeded."
fi
done
done