Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: bookmark icon should be visible for unauthenticated user in article test suite #1157

Merged
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 3 additions & 2 deletions e2e/articles.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ test.describe("Unauthenticated Articles Page", () => {
);
});

test("Should not show bookmark article icon", async ({ page }) => {
test("Should show bookmark article icon", async ({ page }) => {
await page.goto("http://localhost:3000/articles");

await expect(
Expand All @@ -25,7 +25,7 @@ test.describe("Unauthenticated Articles Page", () => {

await expect(
page.locator("article").first().getByLabel("Bookmark this post"),
).toBeHidden();
).toBeVisible();
});
test("Should load more articles when scrolling to the end of the page", async ({
page,
Expand Down Expand Up @@ -164,6 +164,7 @@ test.describe("Authenticated Articles Page", () => {

await expect(page.getByRole("button", { name: "Next" })).toBeVisible();
await page.getByRole("button", { name: "Next" }).click();

await expect(
page.getByRole("button", { name: "Publish now" }),
).toBeVisible();
Expand Down
Loading