diff --git a/src/actions/test-helpers.ts b/src/actions/test-helpers.ts new file mode 100644 index 00000000..bdb74d4d --- /dev/null +++ b/src/actions/test-helpers.ts @@ -0,0 +1,28 @@ +import { vi } from "vitest"; + +export const createMockDb = () => ({ + insert: vi.fn(), + update: vi.fn(), + delete: vi.fn(), + select: vi.fn(), +}); + +export const createMockAuth = () => ({ + auth: vi.fn(), + handlers: {}, + signOut: vi.fn(), +}); + +export const createMockRcon = () => ({ + disconnectUser: vi.fn(), + giveBadge: vi.fn(), + removeBadge: vi.fn(), + alertUser: vi.fn(), + muteUser: vi.fn(), + unmuteUser: vi.fn(), + giveCredits: vi.fn(), +}); + +export const createMockLogStaffActivity = () => vi.fn(); + +export const createMockRevalidatePath = () => vi.fn();