mirror of
https://github.com/paperclipai/paperclip.git
synced 2026-10-24 18:19:05 +02:00
test: compose unsafe export fixture with finalization ownership
Co-Authored-By: Paperclip <noreply@paperclip.ing>
This commit is contained in:
1 parent
9e3b48fc0c
commit
b727a5659d
1 file changed
+4
@@ -2,6 +2,10 @@ import { beforeEach, describe, expect, it, vi } from "vitest";
|
||||
import type { Db } from "@paperclipai/db";
|
||||
|
||||
const sync = vi.hoisted(() => ({ resume: vi.fn() }));
|
||||
vi.mock("./native-workspace-finalization-ownership.js", () => ({
|
||||
withNativeWorkspaceFinalizationOwnership: async (_db: Db, _runId: string, action: (owner: unknown) => unknown) =>
|
||||
action({ token: "fixture-owner", assertHeld: async () => {} }),
|
||||
}));
|
||||
vi.mock("./native-workspace-sync.js", () => ({
|
||||
readNativeWorkspaceSyncReference: () => ({ leaseId: "lease", providerLeaseId: "sandbox", workspaceId: "workspace" }),
|
||||
resumeNativeWorkspaceSync: sync.resume,
|
||||
|
||||
Reference in new issue
Block a user