-
-
Notifications
You must be signed in to change notification settings - Fork 35.8k
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
feat: convert heading challenge test to Playwright #54880
feat: convert heading challenge test to Playwright #54880
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think we need to include the Cypress file deletion in this PR, too?
expect(response?.request().redirectedFrom()?.redirectedTo()?.url()).toContain( | ||
expectedPath | ||
); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Could we simplify the test with:
await page.goto('this-page')
await page.waitForURL('that-page')
await expect(page.getByRole('heading', { name: 'Title of that page' })).toBeVisible()
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
To keep consistency, I think we should go with
await page.goto(input);
await expect(page).toHaveURL(new RegExp(`${expected}/?`));
I am going to block this one as #54897 does the same thing and I want to merge it in to that spec file. |
Checklist:
main
branch of freeCodeCamp.Closes #XXXXX