feat: add privacy, terms, and cookies pages
Footer and login legal links were stubs. Point them at real marketing pages that follow the Figma content-page template.
This commit is contained in:
@@ -110,13 +110,16 @@ describe("Footer (behavioral tests)", () => {
|
||||
expect(screen.queryByText(/all right reserved/i)).not.toBeInTheDocument();
|
||||
});
|
||||
|
||||
it("renders legal links", () => {
|
||||
it("renders legal links to privacy, terms, and cookies pages", () => {
|
||||
render(<Footer />);
|
||||
expect(
|
||||
screen.getAllByRole("link", { name: "Privacy Policy" }).length,
|
||||
).toBeGreaterThan(0);
|
||||
screen.getAllByRole("link", { name: "Privacy Policy" })[0],
|
||||
).toHaveAttribute("href", "/privacy");
|
||||
expect(
|
||||
screen.getAllByRole("link", { name: "Terms of Service" }).length,
|
||||
).toBeGreaterThan(0);
|
||||
screen.getAllByRole("link", { name: "Terms of Service" })[0],
|
||||
).toHaveAttribute("href", "/terms");
|
||||
expect(
|
||||
screen.getAllByRole("link", { name: "Cookies Settings" })[0],
|
||||
).toHaveAttribute("href", "/cookies");
|
||||
});
|
||||
});
|
||||
|
||||
@@ -76,6 +76,16 @@ describe("LoginForm", () => {
|
||||
).toBeInTheDocument();
|
||||
});
|
||||
|
||||
it("links terms and privacy to the legal pages", () => {
|
||||
renderLoginForm();
|
||||
expect(
|
||||
screen.getByRole("link", { name: "Terms of Service" }),
|
||||
).toHaveAttribute("href", "/terms");
|
||||
expect(
|
||||
screen.getByRole("link", { name: "Privacy Policy" }),
|
||||
).toHaveAttribute("href", "/privacy");
|
||||
});
|
||||
|
||||
it("shows validation error when email is invalid", async () => {
|
||||
const user = userEvent.setup();
|
||||
renderLoginForm();
|
||||
|
||||
Reference in New Issue
Block a user