Skip to content

Commit

Permalink
Fix/blog post test (#3277)
Browse files Browse the repository at this point in the history
* Increase viewport on Blog post test

* Add visibility checks for outline in blog tests

* Change blog tests to check for specific outline item count
  • Loading branch information
pdcp1 authored Dec 11, 2024
1 parent 93012b5 commit 05b7f1c
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions site/gatsby-site/playwright/e2e/blog.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -89,8 +89,8 @@ test.describe('Blog', () => {
await page.goto('/es/blog/multilingual-incident-reporting');

await expect(page.locator('[data-cy="outline"]')).toBeVisible();
const outlineItemsCount = await page.locator('[data-cy="outline"] > li').count();
await expect(outlineItemsCount).toBeGreaterThanOrEqual(3);
const outlineItems = page.locator('[data-cy="outline"] > li');
await expect(outlineItems).toHaveCount(4);

await expect(page.locator('[data-cy="outline"]:has-text("¿Como funciona?")')).toBeVisible();
await expect(page.locator('[data-cy="outline"]:has-text("Llamado a la acción")')).toBeVisible();
Expand Down

0 comments on commit 05b7f1c

Please sign in to comment.