]> git.proxmox.com Git - mirror_zfs.git/commitdiff
ZTS: clean up leftover ibackup_trunc files
authorbunder2015 <omfgbunder@gmail.com>
Fri, 13 Apr 2018 17:35:55 +0000 (13:35 -0400)
committerBrian Behlendorf <behlendorf1@llnl.gov>
Fri, 13 Apr 2018 17:35:55 +0000 (10:35 -0700)
zfs_receive_raw_incremental did not clean up ibackup_trunc.* files
left over from running the test.

Also changing the path of the ibackup files so they can be placed
in the correct directories when /var/tmp is not the temporary
directory.

Reviewed-by: Giuseppe Di Natale <dinatale2@llnl.gov>
Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: bunder2015 <omfgbunder@gmail.com>
Closes #7430

tests/zfs-tests/tests/functional/cli_root/zfs_receive/zfs_receive_raw_incremental.ksh

index 48878327b88748c137a9669b9aa1effb7cc52501..1e91c6262c485bc249ac75ef9b33115936077a53 100755 (executable)
@@ -49,14 +49,15 @@ function cleanup
                log_must zfs destroy -r $TESTPOOL/$TESTFS2
 
        [[ -f $ibackup ]] && log_must rm -f $ibackup
+       [[ -f $ibackup_trunc ]] && log_must rm -f $ibackup_trunc
 }
 
 log_onexit cleanup
 
 log_assert "ZFS should receive streams from raw incremental sends"
 
-typeset ibackup="/var/tmp/ibackup.$$"
-typeset ibackup_trunc="/var/tmp/ibackup_trunc.$$"
+typeset ibackup="$TEST_BASE_DIR/ibackup.$$"
+typeset ibackup_trunc="$TEST_BASE_DIR/ibackup_trunc.$$"
 typeset passphrase="password"
 typeset passphrase2="password2"
 typeset snap1="$TESTPOOL/$TESTFS1@snap1"