Skip to content

Add E2E tests for cross-component navigation flow#1119

Closed
BonnieZ-data wants to merge 2 commits into
wordplaydev:mainfrom
BonnieZ-data:main
Closed

Add E2E tests for cross-component navigation flow#1119
BonnieZ-data wants to merge 2 commits into
wordplaydev:mainfrom
BonnieZ-data:main

Conversation

@BonnieZ-data
Copy link
Copy Markdown
Contributor

@BonnieZ-data BonnieZ-data commented May 13, 2026

Context

Adds a new end-to-end test suite covering cross-component navigation interactions — an area with no prior test coverage.

What this tests

  • Home page loads successfully
  • Navigating from home to the Learn page works
  • Navigating from home to the Guide page works
  • Language switcher is visible on the home page

Why this matters

Navigation between the home page and major sections (Learn, Guide) spans multiple Svelte components and had zero E2E test coverage. A regression here would affect all users on first visit.

Related issues

Copy link
Copy Markdown
Collaborator

@amyjko amyjko left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Did you intend to include the SetLiteral.test.ts file in this PR? It seems unrelated to this PR's scope.

Also, there are some brittle domains in the e2e test to fix.

test.describe('Editor → Output cross-component flow', () => {

test('home page loads successfully', async ({ page }) => {
await page.goto('http://localhost:5173/en-US');
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

These should not be hard coded with https://localhost:5173. Just pass the path, not the domain. Not every platform will use this port.

});

test('navigating to Learn page works', async ({ page }) => {
await page.goto('http://localhost:5173/en-US');
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Remove the domain.

});

test('navigating to Guide page works', async ({ page }) => {
await page.goto('http://localhost:5173/en-US');
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Remove the domain.

});

test('language switcher is present on home page', async ({ page }) => {
await page.goto('http://localhost:5173/en-US');
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Remove the domain.

@BonnieZ-data
Copy link
Copy Markdown
Contributor Author

Hi @amyjko , thanks for the feedback! I've removed the hardcoded localhost domains and moved the SetLiteral.test.ts to a separate branch. I'll close this PR and open a new one from the correct branch shortly.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add E2E tests for cross-component navigation flow

2 participants