From 70d2e938b5443821fc48d99c08322a15c3a3c17e Mon Sep 17 00:00:00 2001 From: Brian Behlendorf Date: Fri, 27 Dec 2019 16:41:16 -0800 Subject: [PATCH] ZTS: Replace /var/tmp with $TEST_BASE_DIR Remove a few hardcoded instances of /var/tmp. This should use the $TEST_BASE_DIR in order to allow the ZTS to be optionally run in an alternate directory using `zfs-tests.sh -d `. Reviewed-by: Ryan Moeller Reviewed-by: John Kennedy Reviewed-by: Igor Kozhukhov Reviewed-by: Kjeld Schouten Signed-off-by: Brian Behlendorf Closes #9775 --- .../tests/functional/cli_root/zfs_send/zfs_send_001_pos.ksh | 2 +- .../tests/functional/cli_user/zfs_list/zfs_list_007_pos.ksh | 5 ++--- 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/tests/zfs-tests/tests/functional/cli_root/zfs_send/zfs_send_001_pos.ksh b/tests/zfs-tests/tests/functional/cli_root/zfs_send/zfs_send_001_pos.ksh index b0a319d41..2c6e3fdd6 100755 --- a/tests/zfs-tests/tests/functional/cli_root/zfs_send/zfs_send_001_pos.ksh +++ b/tests/zfs-tests/tests/functional/cli_root/zfs_send/zfs_send_001_pos.ksh @@ -75,7 +75,7 @@ log_onexit cleanup init_snap=$TESTPOOL/$TESTFS@init_snap inc_snap=$TESTPOOL/$TESTFS@inc_snap full_bkup=$TEST_BASE_DIR/fullbkup.$$ -inc_bkup=/var/tmp/incbkup.$$ +inc_bkup=$TEST_BASE_DIR/incbkup.$$ init_data=$TESTDIR/$TESTFILE1 inc_data=$TESTDIR/$TESTFILE2 orig_sum="" diff --git a/tests/zfs-tests/tests/functional/cli_user/zfs_list/zfs_list_007_pos.ksh b/tests/zfs-tests/tests/functional/cli_user/zfs_list/zfs_list_007_pos.ksh index d881b831f..8e9009bd5 100755 --- a/tests/zfs-tests/tests/functional/cli_user/zfs_list/zfs_list_007_pos.ksh +++ b/tests/zfs-tests/tests/functional/cli_user/zfs_list/zfs_list_007_pos.ksh @@ -57,9 +57,8 @@ function cleanup log_onexit cleanup log_assert "'zfs list -d ' should get expected output." -mntpnt=/var/tmp -DEPTH_OUTPUT="$mntpnt/depth_output" -EXPECT_OUTPUT="$mntpnt/expect_output" +DEPTH_OUTPUT="$TEST_BASE_DIR/depth_output" +EXPECT_OUTPUT="$TEST_BASE_DIR/expect_output" typeset -i old_val=0 typeset -i j=0 typeset -i fs=0