test1389 1.7 KB

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