diff options
author | Colin Watson <cjwatson@debian.org> | 2005-05-25 11:01:01 +0000 |
---|---|---|
committer | Colin Watson <cjwatson@debian.org> | 2005-05-25 11:01:01 +0000 |
commit | e88de75a1a236779a10e8ccbcc51d25308be8840 (patch) | |
tree | 7495477a2a7d0cac17a9fcded020b6ea816182ef /regress/sftp-glob.sh | |
parent | 30a0f9443782cd9d7308acd09430bf586186aa55 (diff) | |
parent | 5d05471f6657646d1d6500c7c43134462c407ee6 (diff) |
Merge 4.0p1 to the trunk.
Diffstat (limited to 'regress/sftp-glob.sh')
-rw-r--r-- | regress/sftp-glob.sh | 28 |
1 files changed, 28 insertions, 0 deletions
diff --git a/regress/sftp-glob.sh b/regress/sftp-glob.sh new file mode 100644 index 000000000..e238356a2 --- /dev/null +++ b/regress/sftp-glob.sh | |||
@@ -0,0 +1,28 @@ | |||
1 | # $OpenBSD: sftp-glob.sh,v 1.1 2004/12/10 01:31:30 fgsch Exp $ | ||
2 | # Placed in the Public Domain. | ||
3 | |||
4 | tid="sftp glob" | ||
5 | |||
6 | BASE=${OBJ}/glob | ||
7 | DIR=${BASE}/dir | ||
8 | DATA=${DIR}/file | ||
9 | |||
10 | rm -rf ${BASE} | ||
11 | mkdir -p ${DIR} | ||
12 | touch ${DATA} | ||
13 | |||
14 | verbose "$tid: ls file" | ||
15 | echo "ls -l ${DIR}/fil*" | ${SFTP} -P ${SFTPSERVER} 2>/dev/null | \ | ||
16 | grep ${DATA} >/dev/null 2>&1 | ||
17 | if [ $? -ne 0 ]; then | ||
18 | fail "globbed ls file failed" | ||
19 | fi | ||
20 | |||
21 | verbose "$tid: ls dir" | ||
22 | echo "ls -l ${BASE}/d*" | ${SFTP} -P ${SFTPSERVER} 2>/dev/null | \ | ||
23 | grep file >/dev/null 2>&1 | ||
24 | if [ $? -ne 0 ]; then | ||
25 | fail "globbed ls dir failed" | ||
26 | fi | ||
27 | |||
28 | rm -rf ${BASE} | ||