From 22fb33aa7573f56903a588bf6ca27b9d01e8a006 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=A7=9A=E7=AB=A0=E6=B5=A9?= Date: Mon, 2 Nov 2026 23:00:25 +0800 Subject: [PATCH] =?UTF-8?q?test(library):=20=E4=B8=A4=E6=AC=A1recover?= =?UTF-8?q?=E7=9A=84202=E5=93=8D=E5=BA=94=E7=95=99=E5=9C=A8raw=E9=87=8C?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 第一/第二次 recover 的 HTTP 202 与队列 id 原先只在用例断言里,raw 只留了失败结果。 补两份 accepted 回应,报告可直接引用接口受理证据而不是转述断言。 --- internal/releaseadapter/v071/formal_ds01_negative_r38_test.go | 3 +++ 1 file changed, 3 insertions(+) diff --git a/internal/releaseadapter/v071/formal_ds01_negative_r38_test.go b/internal/releaseadapter/v071/formal_ds01_negative_r38_test.go index a4b8333..dd02d5e 100644 --- a/internal/releaseadapter/v071/formal_ds01_negative_r38_test.go +++ b/internal/releaseadapter/v071/formal_ds01_negative_r38_test.go @@ -368,6 +368,7 @@ WHERE index_name=$1 AND document_id='chunk-target'`, fx.index).Scan(&row); err ! if code != http.StatusAccepted { t.Fatalf("recover with a held dispatch boundary => %d %v", code, accepted) } + save("17n-recover-accepted.json", map[string]any{"http": code, "body": accepted, "window_job_id": job.ID}) queueID, _ := accepted["job"].(map[string]any)["id"].(string) if queueID == "" { t.Fatalf("recover response has no queue job: %v", accepted) @@ -490,6 +491,8 @@ WHERE index_name=$1 AND document_id='chunk-target'`, fx.index).Scan(&row); err ! if secondCode != http.StatusAccepted { t.Fatalf("second recover via the normal API => %d %v", secondCode, secondAccepted) } + save("17n2-second-recover-accepted.json", map[string]any{"http": secondCode, "body": secondAccepted, + "window_job_id": job.ID}) secondQueue, _ := secondAccepted["job"].(map[string]any)["id"].(string) if secondQueue != governance.LibraryRecoveryQueueID(job.ID) { t.Fatalf("second recover queue id = %q, want the window's own %q", secondQueue,