conversation-session-ask-user-question-custom-enter-multi-question.json 4.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116
  1. {
  2. "version": 1,
  3. "caseName": "conversation-session-ask-user-question-custom-enter-multi-question",
  4. "spec": "./test/e2e/conversation-session/permissions/conversation-session-ask-user-question-custom-enter-multi-question.test.ts",
  5. "fixtures": [
  6. {
  7. "id": "conversation-session-ask-user-question-custom-enter-multi-question-title-sidecar",
  8. "description": "多题问答的独立标题响应,正文与答案断言保持不变。",
  9. "metadata": {
  10. "kind": "common",
  11. "source": "synthetic",
  12. "timingPolicy": "fast-text",
  13. "syntheticReason": "隔离回放抓包确认标题旁路缺少响应;为本例提供非流式 JSON 标题,避免 Missing Fixture 或依赖共享旧池。"
  14. },
  15. "match": {
  16. "method": "POST",
  17. "pathIncludes": "/messages",
  18. "bodyIncludes": ["Generate a concise title", "E2E_ASK_USER_QUESTION_CUSTOM_ENTER_MULTI"]
  19. },
  20. "response": {
  21. "statusCode": 200,
  22. "statusMessage": "OK",
  23. "headers": {
  24. "content-type": "application/json; charset=utf-8"
  25. },
  26. "body": "{\"id\":\"upstream-e2e-title-fixture\",\"type\":\"message\",\"role\":\"assistant\",\"model\":\"deepseek-v4-flash\",\"content\":[{\"type\":\"text\",\"text\":\"{\\\"title\\\":\\\"Upstream E2E Fixture\\\"}\"}],\"stop_reason\":\"end_turn\",\"stop_sequence\":null,\"usage\":{\"input_tokens\":125,\"cache_creation_input_tokens\":0,\"cache_read_input_tokens\":0,\"output_tokens\":24,\"service_tier\":\"standard\"}}"
  27. }
  28. },
  29. {
  30. "id": "upstream-conversation-ask-user-question-custom-enter-multi-question-call",
  31. "description": "AskUserQuestion custom Enter repro: 首轮返回两题问答工具调用。",
  32. "metadata": {
  33. "kind": "main",
  34. "timingPolicy": "fast-text",
  35. "source": "synthetic",
  36. "syntheticReason": "稳定制造 AskUserQuestion 多题等待态,复现 custom input Enter 不能提前提交整个问答。"
  37. },
  38. "maxMatches": 1,
  39. "match": {
  40. "method": "POST",
  41. "pathIncludes": "/messages",
  42. "lastUserMessageIncludes": ["E2E_ASK_USER_QUESTION_CUSTOM_ENTER_MULTI"],
  43. "bodyIncludes": [
  44. "E2E_ASK_USER_QUESTION_CUSTOM_ENTER_MULTI",
  45. "E2E_ASK_USER_QUESTION_ENTER_MULTI_TOOL"
  46. ],
  47. "bodyExcludes": ["Generate a concise title", "CRITICAL: Respond with TEXT ONLY"]
  48. },
  49. "response": {
  50. "statusCode": 200,
  51. "toolUse": {
  52. "id": "toolu_e2e_ask_user_question_custom_enter_multi",
  53. "name": "AskUserQuestion",
  54. "input": {
  55. "questions": [
  56. {
  57. "question": "E2E_ASK_USER_QUESTION_ENTER_FIRST: choose the first answer?",
  58. "header": "E2E 1",
  59. "options": [
  60. {
  61. "label": "Use first default",
  62. "description": "Continue the e2e run with the first default answer."
  63. },
  64. {
  65. "label": "Use first fallback",
  66. "description": "Continue the e2e run with the first fallback answer."
  67. }
  68. ]
  69. },
  70. {
  71. "question": "E2E_ASK_USER_QUESTION_ENTER_SECOND: choose the second answer?",
  72. "header": "E2E 2",
  73. "options": [
  74. {
  75. "label": "Use second default",
  76. "description": "Continue the e2e run with the second default answer."
  77. },
  78. {
  79. "label": "Use second fallback",
  80. "description": "Continue the e2e run with the second fallback answer."
  81. }
  82. ]
  83. }
  84. ]
  85. }
  86. }
  87. }
  88. },
  89. {
  90. "id": "upstream-conversation-ask-user-question-custom-enter-multi-question-final",
  91. "description": "AskUserQuestion custom Enter repro: 两题回答都进入下一次模型请求后的最终回复。",
  92. "metadata": {
  93. "kind": "main",
  94. "timingPolicy": "fast-text",
  95. "source": "synthetic",
  96. "syntheticReason": "该响应只证明多题回答已被 agent 消费,核心断言在 Enter 是否错误提前提交。"
  97. },
  98. "maxMatches": 1,
  99. "match": {
  100. "method": "POST",
  101. "pathIncludes": "/messages",
  102. "bodyIncludes": [
  103. "E2E_ASK_USER_QUESTION_ENTER_FIRST_ANSWER",
  104. "E2E_ASK_USER_QUESTION_ENTER_SECOND_ANSWER",
  105. "E2E_ASK_USER_QUESTION_ENTER_MULTI_TOOL",
  106. "toolu_e2e_ask_user_question_custom_enter_multi"
  107. ],
  108. "bodyExcludes": ["Generate a concise title", "CRITICAL: Respond with TEXT ONLY"]
  109. },
  110. "response": {
  111. "statusCode": 200,
  112. "text": "upstream-e2e-ok"
  113. }
  114. }
  115. ]
  116. }