test1359 (1847B)
1 <testcase> 2 <info> 3 <keywords> 4 FTP 5 RETR 6 -J 7 </keywords> 8 </info> 9 10 # Server-side 11 <reply> 12 # file%TESTNUMBER contents... 13 <data nocheck="yes"> 14 HTTP/1.1 200 OK 15 Date: Tue, 09 Nov 2010 14:49:00 GMT 16 Server: test-server/fake 17 Content-Length: 6 18 Connection: close 19 Content-Type: text/html 20 Content-Disposition: filename=name%TESTNUMBER; charset=funny; option=strange 21 22 MOOOO 23 </data> 24 </reply> 25 26 # Client-side 27 <client> 28 <server> 29 ftp 30 </server> 31 <name> 32 FTP download, file with C-D inside, using -O -J -D file 33 </name> 34 <command option="no-output,no-include"> 35 ftp://%HOSTIP:%FTPPORT/path/file%TESTNUMBER -O -J -D %LOGDIR/heads%TESTNUMBER --output-dir %LOGDIR 36 </command> 37 </client> 38 39 # Verify data after the test has been "shot" 40 <verify> 41 <strip> 42 QUIT 43 </strip> 44 <protocol> 45 USER anonymous 46 PASS ftp@example.com 47 PWD 48 CWD path 49 EPSV 50 TYPE I 51 SIZE file%TESTNUMBER 52 RETR file%TESTNUMBER 53 QUIT 54 </protocol> 55 56 <file1 name="%LOGDIR/file%TESTNUMBER"> 57 HTTP/1.1 200 OK 58 Date: Tue, 09 Nov 2010 14:49:00 GMT 59 Server: test-server/fake 60 Content-Length: 6 61 Connection: close 62 Content-Type: text/html 63 Content-Disposition: filename=name%TESTNUMBER; charset=funny; option=strange 64 65 MOOOO 66 </file1> 67 68 <file2 name="%LOGDIR/heads%TESTNUMBER"> 69 220- _ _ ____ _ 70 220- ___| | | | _ \| | 71 220- / __| | | | |_) | | 72 220- | (__| |_| | _ {| |___ 73 220 \___|\___/|_| \_\_____| 74 331 We are happy you popped in! 75 230 Welcome you silly person 76 257 "/" is current directory 77 250 CWD command successful. 78 229 Entering Passive Mode (stripped) 79 200 I modify TYPE as you wanted 80 213 214 81 150 Binary data connection for %TESTNUMBER () (214 bytes). 82 226 File transfer complete 83 </file2> 84 <stripfile2> 85 s/^(229 Entering Passive Mode \().*(\).*)/${1}stripped${2}/ 86 </stripfile2> 87 88 <file3 name="%LOGDIR/stdout%TESTNUMBER"> 89 </file3> 90 91 <notexists> 92 %LOGDIR/name%TESTNUMBER 93 </notexists> 94 </verify> 95 </testcase>