Skip to content

Commit bf6116a

Browse files
committed
test(commands): import backup module after tar mocks
1 parent 74f3124 commit bf6116a

2 files changed

Lines changed: 4 additions & 2 deletions

File tree

src/commands/backup.atomic.test.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,14 +3,15 @@ import os from "node:os";
33
import path from "node:path";
44
import { afterAll, afterEach, beforeAll, beforeEach, describe, expect, it, vi } from "vitest";
55
import { createTempHomeEnv, type TempHomeEnv } from "../test-utils/temp-home.js";
6-
import { backupCreateCommand } from "./backup.js";
76
import {
87
backupVerifyCommandMock,
98
createBackupTestRuntime,
109
mockStateOnlyBackupPlan,
1110
tarCreateMock,
1211
} from "./backup.test-support.js";
1312

13+
const { backupCreateCommand } = await import("./backup.js");
14+
1415
describe("backupCreateCommand atomic archive write", () => {
1516
let tempHome: TempHomeEnv;
1617

src/commands/backup.test.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,14 +11,15 @@ import {
1111
resolveBackupPlanFromPaths,
1212
resolveBackupPlanFromDisk,
1313
} from "./backup-shared.js";
14-
import { backupCreateCommand } from "./backup.js";
1514
import {
1615
backupVerifyCommandMock,
1716
createBackupTestRuntime,
1817
mockStateOnlyBackupPlan,
1918
tarCreateMock,
2019
} from "./backup.test-support.js";
2120

21+
const { backupCreateCommand } = await import("./backup.js");
22+
2223
describe("backup commands", () => {
2324
let tempHome: TempHomeEnv;
2425

0 commit comments

Comments
 (0)