diff options
author | jan <jan@cvs.openbsd.org> | 2020-01-16 19:01:51 +0000 |
---|---|---|
committer | jan <jan@cvs.openbsd.org> | 2020-01-16 19:01:51 +0000 |
commit | a92767892a377349fb7a3384bf5d65a7f8be806c (patch) | |
tree | 1db43a946c8bcc91532c0fb433dee0760138d792 /regress | |
parent | 2137f021ce4d050c8dc2f48748e758d68a4d849f (diff) |
Add a file put sub test for ftpd(8) regression test.
Diffstat (limited to 'regress')
-rw-r--r-- | regress/libexec/ftpd/Makefile | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/regress/libexec/ftpd/Makefile b/regress/libexec/ftpd/Makefile index d2f0eabf995..c0a1562823b 100644 --- a/regress/libexec/ftpd/Makefile +++ b/regress/libexec/ftpd/Makefile @@ -1,13 +1,14 @@ -# $OpenBSD: Makefile,v 1.2 2019/12/26 15:41:50 bluhm Exp $ +# $OpenBSD: Makefile,v 1.3 2020/01/16 19:01:50 jan Exp $ .PHONY: setup-ftpd REGRESS_TARGETS = run-ftpd-get +REGRESS_TARGETS += run-ftpd-put REGRESS_TARGETS += run-ftpd-ls REGRESS_ROOT_TARGETS = ${REGRESS_TARGETS} REGRESS_CLEANUP = cleanup-ftpd REGRESS_SETUP = setup-ftpd -CLEANFILES = ftpd.regress +CLEANFILES = ftpd.regress ftpd.regress.local TCPSERVER = /usr/local/bin/tcpserver FTPD ?= /usr/libexec/ftpd @@ -42,6 +43,7 @@ setup-ftpd: # prepare test files ${SUDO} dd if=/dev/random of="${FTPDIR}/ftpd.regress" count=1 bs=1m ${SUDO} chown ftp:ftp "${FTPDIR}/ftpd.regress" + dd if=/dev/random of="ftpd.regress.local" count=1 bs=1m run-ftpd-get: @echo '\n======== $@ ========' @@ -49,6 +51,12 @@ run-ftpd-get: cmp ${FTPDIR}/ftpd.regress ftpd.regress rm ftpd.regress +run-ftpd-put: + @echo '\n======== $@ ========' + echo put ftpd.regress.local | ftp -a 127.0.0.1 + cmp ${FTPDIR}/ftpd.regress.local ftpd.regress.local + ${SUDO} rm ${FTPDIR}/ftpd.regress.local + run-ftpd-ls: @echo '\n======== $@ ========' echo ls | ftp -a 127.0.0.1 | grep -q 'ftpd.regress' |