test1374 1.5 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879
  1. <testcase>
  2. <info>
  3. <keywords>
  4. HTTP
  5. HTTP GET
  6. </keywords>
  7. </info>
  8. #
  9. <reply>
  10. <data nocheck="yes">
  11. HTTP/1.1 200 OK
  12. Date: Tue, 09 Nov 2010 14:49:00 GMT
  13. Server: test-server/fake
  14. Content-Length: 6
  15. Connection: close
  16. Content-Type: text/html
  17. Content-Disposition: filename=name%TESTNUMBER; charset=funny; option=strange
  18. 12345
  19. </data>
  20. </reply>
  21. #
  22. # Client-side
  23. <client>
  24. <server>
  25. http
  26. </server>
  27. <name>
  28. HTTP GET -o fname -i and Content-Disposition, -D file
  29. </name>
  30. <command option="no-output,no-include">
  31. http://%HOSTIP:%HTTPPORT/%TESTNUMBER -i -o log/outfile%TESTNUMBER -D log/heads%TESTNUMBER
  32. </command>
  33. <postcheck>
  34. perl %SRCDIR/libtest/notexists.pl log/%TESTNUMBER log/name%TESTNUMBER
  35. </postcheck>
  36. </client>
  37. #
  38. # Verify data after the test has been "shot"
  39. <verify>
  40. <protocol>
  41. GET /%TESTNUMBER HTTP/1.1
  42. Host: %HOSTIP:%HTTPPORT
  43. User-Agent: curl/%VERSION
  44. Accept: */*
  45. </protocol>
  46. <file1 name="log/outfile%TESTNUMBER">
  47. HTTP/1.1 200 OK
  48. Date: Tue, 09 Nov 2010 14:49:00 GMT
  49. Server: test-server/fake
  50. Content-Length: 6
  51. Connection: close
  52. Content-Type: text/html
  53. Content-Disposition: filename=name%TESTNUMBER; charset=funny; option=strange
  54. 12345
  55. </file1>
  56. <file2 name="log/heads%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. </file2>
  65. <file3 name="log/stdout%TESTNUMBER">
  66. </file3>
  67. </verify>
  68. </testcase>