Added TOS and PrivPol pages.
All checks were successful
Production PR / QA Tests (pull_request) Successful in 45s

This commit is contained in:
Liviu Burcusel 2026-01-15 15:40:15 +01:00
parent 0add58254d
commit dc65e01bec
Signed by: liviu
GPG key ID: 6CDB37A4AD2C610C
14 changed files with 98 additions and 24 deletions

View file

@ -63,7 +63,7 @@ describe("Default.vue", () => {
});
await flushPromises();
const footer = wrapper.find("[data-testid='footer']");
expect(footer.text()).toBe("Glowing Fiesta 2025 (1.0.1)");
expect(footer.text()).toBe("Glowing Fiesta 2025");
});
it("footer shows range when current year is not 2025", async () => {
@ -75,7 +75,7 @@ describe("Default.vue", () => {
});
await flushPromises();
const footer = wrapper.find("[data-testid='footer']");
expect(footer.text()).toBe("Glowing Fiesta 2025 - 2069 (1.0.1)");
expect(footer.text()).toBe("Glowing Fiesta 2025 - 2069");
});
});
});

View file

@ -3,6 +3,7 @@ import { describe, expect, it, vi, beforeAll, afterAll } from "vitest";
import SidebarLayout from "~/layouts/default/Sidebar.vue";
import { ref } from "vue";
import type * as SidebarUI from "~/components/ui/sidebar";
import { useRuntimeConfig } from "#app";
const { useSidebarMock } = vi.hoisted(() => ({
useSidebarMock: vi.fn(),
@ -112,6 +113,7 @@ vi.mock("lucide-vue-next", () => {
ChevronsUpDown: MockIcon,
CreditCard: MockIcon,
BookOpen: MockIcon,
BookOpenText: MockIcon,
HandCoins: MockIcon,
LogIn: MockIcon,
LogOut: MockIcon,
@ -162,7 +164,7 @@ describe("SidebarLayout", () => {
});
await flushPromises();
expect(wrapper.text()).toContain("Glowing Fiesta");
expect(wrapper.text()).toContain("v1.0.0");
expect(wrapper.text()).toContain(`v${useRuntimeConfig().public.appVersion}`);
});
it("renders sidebar content correctly", async () => {

View file

@ -0,0 +1,11 @@
import { describe, expect, it } from "vitest";
import { mount, type VueWrapper } from "@vue/test-utils";
import PrivacyPolicyPage from "~/pages/legal/privacy-policy.vue";
describe("pages/legal/privacy-policy.vue", () => {
it("loads without crashing", () => {
const wrapper: VueWrapper = mount(PrivacyPolicyPage);
expect(wrapper.exists()).toBe(true);
expect(wrapper.text()).toContain("Privacy Policy");
});
});

View file

@ -0,0 +1,11 @@
import { describe, expect, it } from "vitest";
import { mount, type VueWrapper } from "@vue/test-utils";
import TermsOfServicePage from "~/pages/legal/terms-of-service.vue";
describe("pages/legal/terms-of-service.vue", () => {
it("loads without crashing", () => {
const wrapper: VueWrapper = mount(TermsOfServicePage);
expect(wrapper.exists()).toBe(true);
expect(wrapper.text()).toContain("Terms of Service");
});
});