test2002 1.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117
  1. <testcase>
  2. <info>
  3. <keywords>
  4. HTTP
  5. HTTP GET
  6. FTP
  7. PASV
  8. FILE
  9. TFTP
  10. TFTP RRQ
  11. multiprotocol
  12. </keywords>
  13. </info>
  14. #
  15. # Server-side
  16. <reply>
  17. <data1 nocheck="yes">
  18. HTTP/1.1 200 OK
  19. Date: Tue, 09 Nov 2010 14:49:00 GMT
  20. Server: test-server/fake
  21. Last-Modified: Tue, 13 Jun 2000 12:10:00 GMT
  22. ETag: "21025-dc7-39462498"
  23. Accept-Ranges: bytes
  24. Content-Length: 6
  25. Connection: close
  26. Content-Type: text/html
  27. Funny-head: yesyes
  28. -foo-
  29. </data1>
  30. <data2 nocheck="yes">
  31. data
  32. to
  33. see
  34. that FTP
  35. works
  36. so does it?
  37. </data2>
  38. <data3 nocheck="yes">
  39. a chunk of
  40. data
  41. returned
  42. to TFTP client
  43. </data3>
  44. </reply>
  45. #
  46. # Client-side
  47. <client>
  48. <server>
  49. http
  50. ftp
  51. file
  52. tftp
  53. </server>
  54. <name>
  55. HTTP GET followed by FTP RETR followed by FILE followed by TFTP RRQ
  56. </name>
  57. <command option="no-include">
  58. http://%HOSTIP:%HTTPPORT/%TESTNUMBER0001 ftp://%HOSTIP:%FTPPORT/%TESTNUMBER0002 file://localhost%FILE_PWD/%LOGDIR/test%TESTNUMBER.txt tftp://%HOSTIP:%TFTPPORT//%TESTNUMBER0003
  59. </command>
  60. <file name="%LOGDIR/test%TESTNUMBER.txt">
  61. foo
  62. bar
  63. bar
  64. foo
  65. moo
  66. </file>
  67. </client>
  68. #
  69. # Verify data after the test has been "shot"
  70. <verify>
  71. <strip>
  72. ^timeout = [5-6]$
  73. </strip>
  74. <protocol>
  75. GET /%TESTNUMBER0001 HTTP/1.1
  76. Host: %HOSTIP:%HTTPPORT
  77. User-Agent: curl/%VERSION
  78. Accept: */*
  79. USER anonymous
  80. PASS ftp@example.com
  81. PWD
  82. EPSV
  83. TYPE I
  84. SIZE %TESTNUMBER0002
  85. RETR %TESTNUMBER0002
  86. opcode = 1
  87. mode = octet
  88. tsize = 0
  89. blksize = 512
  90. filename = /%TESTNUMBER0003
  91. QUIT
  92. </protocol>
  93. <stdout>
  94. -foo-
  95. data
  96. to
  97. see
  98. that FTP
  99. works
  100. so does it?
  101. foo
  102. bar
  103. bar
  104. foo
  105. moo
  106. a chunk of
  107. data
  108. returned
  109. to TFTP client
  110. </stdout>
  111. </verify>
  112. </testcase>