conversation-session-v4-queue.json 3.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687
  1. {
  2. "version": 1,
  3. "caseName": "conversation-session-v4-queue",
  4. "spec": "./test/e2e/conversation-session/queue/conversation-session-v4-queue.test.ts",
  5. "fixtures": [
  6. {
  7. "id": "v4-queue-title",
  8. "description": "E2E_V4_QUEUE_SLOW 首发的 case-local 标题生成响应。",
  9. "metadata": {
  10. "kind": "common",
  11. "timingPolicy": "fast-text",
  12. "source": "synthetic",
  13. "syntheticReason": "E2E_V4_QUEUE_SLOW 首发会触发默认 title sidecar;固定 case-local 标题响应,避免 default replay 回退 legacy provider-basic,并用该首发 marker 隔离跨 case 匹配。"
  14. },
  15. "match": {
  16. "method": "POST",
  17. "pathIncludes": "/messages",
  18. "bodyIncludes": ["Generate a concise title", "E2E_V4_QUEUE_SLOW"]
  19. },
  20. "response": {
  21. "statusCode": 200,
  22. "text": {
  23. "id": "v4-queue-title",
  24. "inputTokens": 64,
  25. "outputTokens": 8,
  26. "text": "{\"title\":\"V4 Queue E2E\"}"
  27. }
  28. }
  29. },
  30. {
  31. "id": "v4-queue-slow-turn",
  32. "description": "M4/B09 queue 门禁:可控慢流首轮,保持 running 以便后续 sendText 入队并冻结编辑。",
  33. "metadata": {
  34. "kind": "main",
  35. "timingPolicy": "controlled-stream",
  36. "source": "synthetic",
  37. "syntheticReason": "用稳定 running 窗口建立 queue,并可 stop 进入 held;验证 delete/reorder 的 CLI 权威投影,以及冻结编辑在 lock ACK 后进入发起端 composer 编辑态、提交原地替换。"
  38. },
  39. "match": {
  40. "method": "POST",
  41. "pathIncludes": "/messages",
  42. "lastUserMessageIncludes": ["E2E_V4_QUEUE_SLOW"],
  43. "bodyExcludes": ["Generate a concise title", "CRITICAL: Respond with TEXT ONLY"]
  44. },
  45. "response": {
  46. "statusCode": 200,
  47. "statusMessage": "OK",
  48. "headers": {
  49. "cache-control": "no-cache",
  50. "content-type": "text/event-stream; charset=utf-8"
  51. },
  52. "chunks": [
  53. {
  54. "offsetMs": 0,
  55. "text": "event: message_start\ndata: {\"type\":\"message_start\",\"message\":{\"id\":\"v4-queue-slow\",\"type\":\"message\",\"role\":\"assistant\",\"model\":\"deepseek-v4-flash\",\"content\":[],\"stop_reason\":null,\"stop_sequence\":null,\"usage\":{\"input_tokens\":80,\"cache_creation_input_tokens\":0,\"cache_read_input_tokens\":0,\"output_tokens\":0,\"service_tier\":\"standard\"}}}\n\n"
  56. },
  57. {
  58. "offsetMs": 250,
  59. "text": "event: content_block_start\ndata: {\"type\":\"content_block_start\",\"index\":0,\"content_block\":{\"type\":\"text\",\"text\":\"\"}}\n\n"
  60. },
  61. {
  62. "offsetMs": 500,
  63. "text": "event: content_block_delta\ndata: {\"type\":\"content_block_delta\",\"index\":0,\"delta\":{\"type\":\"text_delta\",\"text\":\"V4_QUEUE_STREAMING \"}}\n\n"
  64. },
  65. {
  66. "offsetMs": 45000,
  67. "text": "event: content_block_stop\ndata: {\"type\":\"content_block_stop\",\"index\":0}\n\n"
  68. },
  69. {
  70. "offsetMs": 45100,
  71. "text": "event: message_delta\ndata: {\"type\":\"message_delta\",\"delta\":{\"stop_reason\":\"end_turn\",\"stop_sequence\":null},\"usage\":{\"input_tokens\":80,\"output_tokens\":4,\"service_tier\":\"standard\"}}\n\n"
  72. },
  73. {
  74. "offsetMs": 45200,
  75. "text": "event: message_stop\ndata: {\"type\":\"message_stop\"}\n\n"
  76. }
  77. ],
  78. "text": {
  79. "id": "v4-queue-slow",
  80. "inputTokens": 80,
  81. "outputTokens": 4,
  82. "text": "V4_QUEUE_STREAMING"
  83. }
  84. }
  85. }
  86. ]
  87. }