summaryrefslogtreecommitdiffstats
path: root/regress/test-exec.sh
diff options
context:
space:
mode:
authorDarren Tucker <dtucker@zip.com.au>2013-05-17 07:32:29 +0200
committerDarren Tucker <dtucker@zip.com.au>2013-05-17 07:32:29 +0200
commit59d928d3b47e8298f4a8b4b3fb37fb8c8ce1b098 (patch)
tree69e341bea63449e27da3bcb836b646c7c40a6b4f /regress/test-exec.sh
parent - dtucker@cvs.openbsd.org 2013/05/17 01:32:11 (diff)
downloadopenssh-59d928d3b47e8298f4a8b4b3fb37fb8c8ce1b098.tar.xz
openssh-59d928d3b47e8298f4a8b4b3fb37fb8c8ce1b098.zip
- dtucker@cvs.openbsd.org 2013/05/17 04:29:14
[regress/sftp.sh regress/putty-ciphers.sh regress/cipher-speed.sh regress/test-exec.sh regress/sftp-batch.sh regress/dynamic-forward.sh regress/putty-transfer.sh regress/conch-ciphers.sh regress/sftp-cmds.sh regress/scp.sh regress/ssh-com-sftp.sh regress/rekey.sh regress/putty-kex.sh regress/stderr-data.sh regress/stderr-after-eof.sh regress/sftp-badcmds.sh regress/reexec.sh regress/ssh-com-client.sh regress/sftp-chroot.sh regress/forwarding.sh regress/transfer.sh regress/multiplex.sh] Move the setting of DATA and COPY into test-exec.sh
Diffstat (limited to 'regress/test-exec.sh')
-rw-r--r--regress/test-exec.sh15
1 files changed, 10 insertions, 5 deletions
diff --git a/regress/test-exec.sh b/regress/test-exec.sh
index 0680eaa94..599b8d9ba 100644
--- a/regress/test-exec.sh
+++ b/regress/test-exec.sh
@@ -1,4 +1,4 @@
-# $OpenBSD: test-exec.sh,v 1.41 2013/05/17 00:37:40 dtucker Exp $
+# $OpenBSD: test-exec.sh,v 1.42 2013/05/17 04:29:14 dtucker Exp $
# Placed in the Public Domain.
#SUDO=sudo
@@ -155,10 +155,6 @@ fi
>$TEST_SSHD_LOGFILE
>$TEST_REGRESS_LOGFILE
-# Some data for test copies
-DATA=$OBJ/testdata
-cat $SSHD${EXEEXT} $SSHD${EXEEXT} $SSHD${EXEEXT} $SSHD${EXEEXT} >$DATA
-
# Create wrapper ssh with logging. We can't just specify "SSH=ssh -E..."
# because sftp and scp don't handle spaces in arguments.
SSHLOGWRAP=$OBJ/ssh-log-wrapper.sh
@@ -168,6 +164,15 @@ echo "exec ${SSH} -E${TEST_SSH_LOGFILE} "'"$@"' >>$SSHLOGWRAP
chmod a+rx $OBJ/ssh-log-wrapper.sh
SSH="$SSHLOGWRAP"
+# Some test data. We make a copy because some tests will overwrite it.
+# The tests may assume that $DATA exists and is writable and $COPY does
+# not exist.
+DATA=$OBJ/data
+cat $SSHD $SSHD $SSHD $SSHD >${DATA}
+chmod u+w ${DATA}
+COPY=$OBJ/copy
+rm -f ${COPY}
+
# these should be used in tests
export SSH SSHD SSHAGENT SSHADD SSHKEYGEN SSHKEYSCAN SFTP SFTPSERVER SCP
#echo $SSH $SSHD $SSHAGENT $SSHADD $SSHKEYGEN $SSHKEYSCAN $SFTP $SFTPSERVER $SCP