chore: fix linting issues

This commit is contained in:
Nicolas Meienberger 2026-04-01 20:02:02 +02:00
parent d8bf4c2ef3
commit 0f098a8f71
2 changed files with 15 additions and 12 deletions

View file

@ -7,7 +7,7 @@ import {
createTestSessionWithRegularMember, createTestSessionWithRegularMember,
getAuthHeaders, getAuthHeaders,
} from "~/test/helpers/auth"; } from "~/test/helpers/auth";
import { account, invitation, member, organization, ssoProvider, usersTable } from "~/server/db/schema"; import { account } from "~/server/db/schema";
import { db } from "~/server/db/db"; import { db } from "~/server/db/db";
const app = createApp(); const app = createApp();

View file

@ -252,18 +252,21 @@ describe("repositoriesService.dumpSnapshot", () => {
}, },
]); ]);
const dumpMock = vi.fn( const dumpMock = vi.fn((_config: unknown, snapshotRef: string, options: Parameters<typeof restic.dump>[2]) => {
(_config: unknown, snapshotRef: string, options: { organizationId: string; path: string; archive?: false }) => if (!options.path) {
Promise.resolve( throw new Error("Expected dump path in test");
createDumpResult( }
JSON.stringify({
snapshotRef, return Promise.resolve(
path: options.path, createDumpResult(
archive: options.archive !== false, JSON.stringify({
}), snapshotRef,
), path: options.path,
archive: options.archive !== false,
}),
), ),
); );
});
vi.spyOn(restic, "dump").mockImplementation(dumpMock); vi.spyOn(restic, "dump").mockImplementation(dumpMock);
return { return {