test1195 1.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263
  1. <testcase>
  2. <info>
  3. <keywords>
  4. MQTT
  5. MQTT SUBSCRIBE
  6. </keywords>
  7. </info>
  8. #
  9. # Server-side
  10. <reply>
  11. <data nocheck="yes">
  12. hello
  13. </data>
  14. <datacheck hex="yes">
  15. 00 04 31 31 39 30 68 65 6c 6c 6f 5b 4c 46 5d 0a
  16. </datacheck>
  17. <servercmd>
  18. PUBLISH-before-SUBACK TRUE
  19. short-PUBLISH TRUE
  20. </servercmd>
  21. </reply>
  22. #
  23. # Client-side
  24. <client>
  25. <features>
  26. mqtt
  27. </features>
  28. <server>
  29. mqtt
  30. </server>
  31. <name>
  32. MQTT SUBSCRIBE with short PUBLISH
  33. </name>
  34. <command option="binary-trace">
  35. mqtt://%HOSTIP:%MQTTPORT/%TESTNUMBER
  36. </command>
  37. </client>
  38. #
  39. # Verify data after the test has been "shot"
  40. <verify>
  41. # These are hexadecimal protocol dumps from the client
  42. #
  43. # Strip out the random part of the client id from the CONNECT message
  44. # before comparison
  45. <strippart>
  46. s/^(.* 00044d5154540402003c000c6375726c).*/$1/
  47. </strippart>
  48. <protocol>
  49. client CONNECT 18 00044d5154540402003c000c6375726c
  50. server CONNACK 2 20020000
  51. client SUBSCRIBE 9 000100043131393500
  52. server PUBLISH c 300c00043131393568656c6c
  53. </protocol>
  54. # 18 is CURLE_PARTIAL_FILE
  55. <errorcode>
  56. 18
  57. </errorcode>
  58. </verify>
  59. </testcase>