{ "version": 1, "caseName": "conversation-session-running-queue", "spec": "./test/e2e/conversation-session/queue/conversation-session-running-queue.test.ts", "fixtures": [ { "id": "upstream-running-queue-first-slow-stream", "description": "A03-A08 running queue 首轮慢流,稳定制造 running 窗口。", "metadata": { "kind": "main", "source": "synthetic", "timingPolicy": "controlled-stream", "syntheticReason": "真实首轮输出后保持流;队列交互全部结束再由用户 Stop 收口,不靠延时或自然完成跳过断言。" }, "maxMatches": 1, "match": { "method": "POST", "pathIncludes": "/messages", "bodyIncludes": ["E2E_SLOW_STREAM", "E2E_RUNNING_QUEUE_FIRST"], "bodyExcludes": ["Generate a concise title", "CRITICAL: Respond with TEXT ONLY"], "lastUserMessageIncludes": ["E2E_RUNNING_QUEUE_FIRST"] }, "response": { "statusCode": 200, "headers": { "cache-control": "no-cache", "content-type": "text/event-stream; charset=utf-8" }, "body": "event: message_start\ndata: {\"type\":\"message_start\",\"message\":{\"id\":\"upstream-e2e-running-queue-first-slow-stream\",\"type\":\"message\",\"role\":\"assistant\",\"model\":\"deepseek-v4-flash\",\"content\":[],\"stop_reason\":null,\"stop_sequence\":null,\"usage\":{\"input_tokens\":120,\"cache_creation_input_tokens\":0,\"cache_read_input_tokens\":0,\"output_tokens\":0,\"service_tier\":\"standard\"}}}\n\nevent: content_block_start\ndata: {\"type\":\"content_block_start\",\"index\":0,\"content_block\":{\"type\":\"text\",\"text\":\"\"}}\n\nevent: content_block_delta\ndata: {\"type\":\"content_block_delta\",\"index\":0,\"delta\":{\"type\":\"text_delta\",\"text\":\"deep\"}}\n\nevent: content_block_delta\ndata: {\"type\":\"content_block_delta\",\"index\":0,\"delta\":{\"type\":\"text_delta\",\"text\":\"seek\"}}\n\nevent: content_block_delta\ndata: {\"type\":\"content_block_delta\",\"index\":0,\"delta\":{\"type\":\"text_delta\",\"text\":\"-e2e-ok\"}}\n\nevent: content_block_stop\ndata: {\"type\":\"content_block_stop\",\"index\":0}\n\nevent: message_delta\ndata: {\"type\":\"message_delta\",\"delta\":{\"stop_reason\":\"end_turn\",\"stop_sequence\":null},\"usage\":{\"input_tokens\":120,\"output_tokens\":12,\"service_tier\":\"standard\"}}\n\nevent: message_stop\ndata: {\"type\":\"message_stop\"}\n\n", "chunks": [ { "text": "event: message_start\ndata: {\"type\":\"message_start\",\"message\":{\"id\":\"upstream-e2e-running-queue-first-slow-stream\",\"type\":\"message\",\"role\":\"assistant\",\"model\":\"deepseek-v4-flash\",\"content\":[],\"stop_reason\":null,\"stop_sequence\":null,\"usage\":{\"input_tokens\":120,\"cache_creation_input_tokens\":0,\"cache_read_input_tokens\":0,\"output_tokens\":0,\"service_tier\":\"standard\"}}}\n\n", "delayMs": 0 }, { "text": "event: content_block_start\ndata: {\"type\":\"content_block_start\",\"index\":0,\"content_block\":{\"type\":\"text\",\"text\":\"\"}}\n\n", "delayMs": 0 }, { "text": "event: content_block_delta\ndata: {\"type\":\"content_block_delta\",\"index\":0,\"delta\":{\"type\":\"text_delta\",\"text\":\"deep\"}}\n\n", "delayMs": 0 }, { "text": "event: content_block_delta\ndata: {\"type\":\"content_block_delta\",\"index\":0,\"delta\":{\"type\":\"text_delta\",\"text\":\"seek\"}}\n\n", "delayMs": 0 }, { "text": "event: content_block_delta\ndata: {\"type\":\"content_block_delta\",\"index\":0,\"delta\":{\"type\":\"text_delta\",\"text\":\"-e2e-ok\"}}\n\n", "delayMs": 0 }, { "text": "event: content_block_stop\ndata: {\"type\":\"content_block_stop\",\"index\":0}\n\n", "delayMs": 0 }, { "text": "event: message_delta\ndata: {\"type\":\"message_delta\",\"delta\":{\"stop_reason\":\"end_turn\",\"stop_sequence\":null},\"usage\":{\"input_tokens\":120,\"output_tokens\":12,\"service_tier\":\"standard\"}}\n\n", "delayMs": 0 }, { "text": "event: message_stop\ndata: {\"type\":\"message_stop\"}\n\n", "delayMs": 0 } ], "releaseAfterChunks": 3 } }, { "id": "upstream-running-queue-second-queued-contract", "description": "A03-A06 second queued marker 合同占位;running 中不应立即发 provider。", "metadata": { "kind": "main", "timingPolicy": "fast-text", "source": "synthetic", "syntheticReason": "该 queued text 的产品语义是不打断当前轮且暂不发送;fixture 只覆盖 marker 合同。" }, "maxMatches": 0, "match": { "method": "POST", "pathIncludes": "/messages", "bodyIncludes": ["E2E_RUNNING_QUEUE_SECOND"], "bodyExcludes": ["Generate a concise title", "CRITICAL: Respond with TEXT ONLY"], "lastUserMessageIncludes": ["E2E_RUNNING_QUEUE_SECOND"] }, "response": { "statusCode": 200, "text": { "id": "upstream-e2e-running-queue-second-should-not-send", "inputTokens": 128, "outputTokens": 12, "text": "upstream-e2e-ok" } } }, { "id": "upstream-running-queue-third-queued-contract", "description": "A03-A06 third queued marker 合同占位;running 中不应立即发 provider。", "metadata": { "kind": "main", "timingPolicy": "fast-text", "source": "synthetic", "syntheticReason": "该 queued text 的产品语义是不打断当前轮且暂不发送;fixture 只覆盖 marker 合同。" }, "maxMatches": 0, "match": { "method": "POST", "pathIncludes": "/messages", "bodyIncludes": ["E2E_RUNNING_QUEUE_THIRD"], "bodyExcludes": ["Generate a concise title", "CRITICAL: Respond with TEXT ONLY"], "lastUserMessageIncludes": ["E2E_RUNNING_QUEUE_THIRD"] }, "response": { "statusCode": 200, "text": { "id": "upstream-e2e-running-queue-third-should-not-send", "inputTokens": 128, "outputTokens": 12, "text": "upstream-e2e-ok" } } }, { "id": "upstream-running-queue-fourth-queued-contract", "description": "A03-A06 fourth queued marker 合同占位;running 中不应立即发 provider。", "metadata": { "kind": "main", "timingPolicy": "fast-text", "source": "synthetic", "syntheticReason": "该 queued text 的产品语义是不打断当前轮且暂不发送;fixture 只覆盖 marker 合同。" }, "maxMatches": 0, "match": { "method": "POST", "pathIncludes": "/messages", "bodyIncludes": ["E2E_RUNNING_QUEUE_FOURTH"], "bodyExcludes": ["Generate a concise title", "CRITICAL: Respond with TEXT ONLY"], "lastUserMessageIncludes": ["E2E_RUNNING_QUEUE_FOURTH"] }, "response": { "statusCode": 200, "text": { "id": "upstream-e2e-running-queue-fourth-should-not-send", "inputTokens": 128, "outputTokens": 12, "text": "upstream-e2e-ok" } } }, { "id": "upstream-running-queue-fifth-queued-contract", "description": "A03-A06 fifth queued marker 合同占位;running 中不应立即发 provider。", "metadata": { "kind": "main", "timingPolicy": "fast-text", "source": "synthetic", "syntheticReason": "该 queued text 的产品语义是不打断当前轮且暂不发送;fixture 只覆盖 marker 合同。" }, "maxMatches": 0, "match": { "method": "POST", "pathIncludes": "/messages", "bodyIncludes": ["E2E_RUNNING_QUEUE_FIFTH"], "bodyExcludes": ["Generate a concise title", "CRITICAL: Respond with TEXT ONLY"], "lastUserMessageIncludes": ["E2E_RUNNING_QUEUE_FIFTH"] }, "response": { "statusCode": 200, "text": { "id": "upstream-e2e-running-queue-fifth-should-not-send", "inputTokens": 128, "outputTokens": 12, "text": "upstream-e2e-ok" } } }, { "id": "upstream-running-queue-goal-queued-contract", "description": "A07 running 中 /goal 入队合同占位;不应立即发 provider。", "metadata": { "kind": "main", "timingPolicy": "fast-text", "source": "synthetic", "syntheticReason": "running 中 /goal 只进入本地 queue,不能立即触发 provider 请求。" }, "maxMatches": 0, "match": { "method": "POST", "pathIncludes": "/messages", "bodyIncludes": ["E2E_RUNNING_QUEUE_GOAL"], "bodyExcludes": ["Generate a concise title", "CRITICAL: Respond with TEXT ONLY"], "lastUserMessageIncludes": ["E2E_RUNNING_QUEUE_GOAL"] }, "response": { "statusCode": 200, "text": { "id": "upstream-e2e-running-queue-goal-should-not-send", "inputTokens": 128, "outputTokens": 12, "text": "upstream-e2e-ok" } } } ] }