merge: fix/b-download
Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01Cxwgnn2pbzQ7rXv3rq7fei
This commit is contained in:
commit
15d7f2ec2f
10 files changed
+566
-18
No files matched your search
@@ -41,6 +41,8 @@ describe.skipIf(!hasPg)("E15 Agent 质量(fake 模型 + 真实能力)", () => {
|
||||
name: "Dune.Part.Two.2024.1080p.BluRay.x264-GRP",
|
||||
status: "failed",
|
||||
last_error: JSON.stringify({ message: "qB 状态 missingFiles" }),
|
||||
// 已连续缺席两轮:下一轮同步即确认移除(多轮缺席才判移除)
|
||||
missing_count: 2,
|
||||
})
|
||||
.returning("id")
|
||||
.executeTakeFirstOrThrow()
|
||||
|
||||
@@ -2,7 +2,7 @@ import { createQbClient } from "@umt/adapters";
|
||||
import { afterAll, beforeAll, describe, expect, it } from "vitest";
|
||||
import type { createAcquisitionOrganizeModule } from "../../src/modules/acquisition-organize/index.ts";
|
||||
import { evaluateAcquisition } from "../../src/modules/acquisition-organize/services/acquisition.ts";
|
||||
import { syncDownloads } from "../../src/modules/acquisition-organize/services/downloads.ts";
|
||||
import { MISSING_CONFIRM_ROUNDS, syncDownloads } from "../../src/modules/acquisition-organize/services/downloads.ts";
|
||||
import { torrentFor } from "./fixtures/modules.ts";
|
||||
import { createE2E, type E2E, pgAvailable, seedBase, waitFor } from "./harness.ts";
|
||||
|
||||
@@ -206,7 +206,8 @@ describe.skipIf(!hasPg)("E8 AT24 标签移除 / 任务消失", () => {
|
||||
});
|
||||
await ext.delete([ids.D.hash], { deleteFiles: false });
|
||||
const externalDeletes = e.qb.callsTo("torrents/delete").length;
|
||||
await syncDownloads(deps());
|
||||
// 连续多轮查不到才确认移除
|
||||
for (let i = 0; i < MISSING_CONFIRM_ROUNDS; i++) await syncDownloads(deps());
|
||||
const row = await dt("D");
|
||||
expect(row.status).toBe("removed");
|
||||
expect(row.removed_at).not.toBeNull();
|
||||
|
||||
Reference in new issue
Block a user