diff options
author | Matthew Ahrens <[email protected]> | 2020-02-27 09:37:34 -0800 |
---|---|---|
committer | GitHub <[email protected]> | 2020-02-27 09:37:34 -0800 |
commit | ab9646166d4f1fb01f648c678e896ea05a9517f6 (patch) | |
tree | d47eb1716001f18048cc46856e5c82fe4a6dd4bf | |
parent | 2c3a83701dd185cadb30db4556256534e2930c7d (diff) |
ZTS: Fix zfs_receive_004_neg
`zfs recv` of an incremental stream that already exists is ignored, with
a message like:
receiving incremental stream of pool/fs@incsnap into pool/fs@incsnap
snap testpool/testfs@incsnap already exists; ignoring
And the command exits successfully (exit code 0).
The zfs_receive_004_neg test is expecting that a this case will fail,
with nonzero exit code.
The fix is to remove this specific command from the test case. This
lets us check that the remaining commands do in fact fail.
Reviewed-by: Ryan Moeller <[email protected]>
Reviewed-by: George Melikov <[email protected]>
Reviewed-by: Brian Behlendorf <[email protected]>
Signed-off-by: Matthew Ahrens <[email protected]>
Closes #10055
-rwxr-xr-x | tests/test-runner/bin/zts-report.py | 1 | ||||
-rwxr-xr-x | tests/zfs-tests/tests/functional/cli_root/zfs_receive/zfs_receive_004_neg.ksh | 7 |
2 files changed, 1 insertions, 7 deletions
diff --git a/tests/test-runner/bin/zts-report.py b/tests/test-runner/bin/zts-report.py index 111686920..19730aaaf 100755 --- a/tests/test-runner/bin/zts-report.py +++ b/tests/test-runner/bin/zts-report.py @@ -147,7 +147,6 @@ summary = { known = { 'casenorm/mixed_none_lookup_ci': ['FAIL', '7633'], 'casenorm/mixed_formd_lookup_ci': ['FAIL', '7633'], - 'cli_root/zfs_receive/zfs_receive_004_neg': ['FAIL', known_reason], 'cli_root/zfs_unshare/zfs_unshare_002_pos': ['SKIP', na_reason], 'cli_root/zfs_unshare/zfs_unshare_006_pos': ['SKIP', na_reason], 'cli_user/misc/zfs_share_001_neg': ['SKIP', na_reason], diff --git a/tests/zfs-tests/tests/functional/cli_root/zfs_receive/zfs_receive_004_neg.ksh b/tests/zfs-tests/tests/functional/cli_root/zfs_receive/zfs_receive_004_neg.ksh index 3a9c2279a..56f536225 100755 --- a/tests/zfs-tests/tests/functional/cli_root/zfs_receive/zfs_receive_004_neg.ksh +++ b/tests/zfs-tests/tests/functional/cli_root/zfs_receive/zfs_receive_004_neg.ksh @@ -92,16 +92,11 @@ sync set -A badargs \ "" "nonexistent-snap" "blah@blah" "-d" "-d nonexistent-dataset" \ - "$TESTPOOL/$TESTFS" "$TESTPOOL1" "$TESTPOOL/fs@" "$TESTPOOL/fs@@mysnap" \ + "$TESTPOOL1" "$TESTPOOL/fs@" "$TESTPOOL/fs@@mysnap" \ "$TESTPOOL/fs@@" "$TESTPOOL/fs/@mysnap" "$TESTPOOL/fs@/mysnap" \ "$TESTPOOL/nonexistent-fs/nonexistent-fs" "-d $TESTPOOL/nonexistent-fs" \ "-d $TESTPOOL/$TESTFS/nonexistent-fs" -if is_global_zone ; then - typeset -i n=${#badargs[@]} - badargs[$n]="-d $TESTPOOL" -fi - typeset -i i=0 while (( i < ${#badargs[*]} )) do |