test1801 942 B

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667
  1. <testcase>
  2. <info>
  3. <keywords>
  4. HTTP
  5. HTTP/2
  6. </keywords>
  7. </info>
  8. # Server-side
  9. <reply>
  10. <data>
  11. HTTP/1.1 101 Switching!
  12. HTTP/1.1 200 OK
  13. Date: Tue, 09 Nov 2010 14:49:00 GMT
  14. Server: test-server/fake
  15. Last-Modified: Tue, 13 Jun 2000 12:10:00 GMT
  16. Content-Length: 6
  17. Content-Type: text/html
  18. lies!
  19. </data>
  20. <datacheck>
  21. HTTP/1.1 101 Switching!
  22. </datacheck>
  23. # listen to the upgrade request!
  24. <servercmd>
  25. upgrade
  26. </servercmd>
  27. </reply>
  28. # Client-side
  29. <client>
  30. <server>
  31. http
  32. </server>
  33. <features>
  34. http/2
  35. </features>
  36. <name>
  37. HTTP/2 upgrade with lying server
  38. </name>
  39. <command>
  40. http://%HOSTIP:%HTTPPORT/%TESTNUMBER --http2
  41. </command>
  42. </client>
  43. <verify>
  44. <protocol>
  45. GET /%TESTNUMBER HTTP/1.1
  46. Host: %HOSTIP:%HTTPPORT
  47. User-Agent: curl/%VERSION
  48. Accept: */*
  49. Connection: Upgrade, HTTP2-Settings
  50. Upgrade: %H2CVER
  51. HTTP2-Settings: AAMAAABkAARAAAAAAAIAAAAA
  52. </protocol>
  53. # CURLE_HTTP2: Send failure: Broken pipe
  54. <errorcode>
  55. 16
  56. </errorcode>
  57. </verify>
  58. </testcase>