8 primevue install (#9)
* Added PrimeVue with TailwindCSS support and modified Homepage to test the changes. * Configured vitest to use PrimeVue and wrote a quick test for home page
This commit is contained in:
parent
b27e3655d1
commit
82acb354ca
9 changed files with 975 additions and 5 deletions
11
tests/pages/index.test.ts
Normal file
11
tests/pages/index.test.ts
Normal file
|
|
@ -0,0 +1,11 @@
|
|||
import { describe, expect, it } from "vitest";
|
||||
import { mount, type VueWrapper } from "@vue/test-utils";
|
||||
import IndexPage from "~/app/pages/index.vue";
|
||||
|
||||
describe("pages/index.vue", () => {
|
||||
const wrapper: VueWrapper = mount(IndexPage, {});
|
||||
|
||||
it("loads without crashing", () => {
|
||||
expect(wrapper.exists()).toBe(true);
|
||||
});
|
||||
});
|
||||
|
|
@ -1,4 +1,7 @@
|
|||
import { vi } from "vitest";
|
||||
import { config } from "@vue/test-utils";
|
||||
import PrimeVue from "primevue/config";
|
||||
import Button from "primevue/button";
|
||||
|
||||
Object.defineProperty(global, "import", {
|
||||
value: {
|
||||
|
|
@ -8,3 +11,7 @@ Object.defineProperty(global, "import", {
|
|||
},
|
||||
writable: true,
|
||||
});
|
||||
|
||||
config.global.plugins = [PrimeVue];
|
||||
config.global.stubs = { NuxtPage: true };
|
||||
config.global.components = { Button };
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue