glowing-fiesta-original/tests/setup.ts
Liviu Burcusel 97211cdccd
Some checks failed
Production Build and Deploy / Build (push) Failing after 44s
Production Build and Deploy / Deploy (push) Has been skipped
[Closes #8] Added authentication
2026-01-07 11:11:35 +01:00

28 lines
711 B
TypeScript

import { vi } from "vitest";
import { config } from "@vue/test-utils";
import * as vue from "vue";
(global as any).ref = vue.ref;
(global as any).reactive = vue.reactive;
(global as any).computed = vue.computed;
(global as any).watch = vue.watch;
(global as any).onMounted = vue.onMounted;
(global as any).onUnmounted = vue.onUnmounted;
Object.defineProperty(global, "import", {
value: {
meta: {
glob: vi.fn(() => ({})),
},
},
writable: true,
});
config.global.stubs = {
NuxtLayout: true,
NuxtPage: true,
Divider: true,
NuxtRouteAnnouncer: true,
NuxtLink: { template: "<a><slot /></a>", props: ["to"] },
ClientOnly: { template: "<div class='client-only'><slot /></div>" },
};