-
Notifications
You must be signed in to change notification settings - Fork 2k
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
[GB 15.8][E2E][Instagram Block] Use a different locator depending on the type of site for clicking the "Embed" button #77228
Merged
fullofcaffeine
merged 1 commit into
trunk
from
fix/gb-e2e-failing-on-simple-sites-gb-15.8
May 23, 2023
Merged
Changes from all commits
Commits
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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'm honestly not sure if it's related to the Gutenframe or some other modification that's simple-specific. I decided not to spend much time on it since this solution works; but it'd be nice if we could find a single locator that would work for both in the future, though not critical -- I think it's also OK to use a conditional around the site type if needed.
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'm not sure why
await editorCanvas.getByRole( 'button', { name: 'Embed' } ).click()
would not work for both cases here. Were you seeing a failure on Simple sites?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.
Looks like the new selector is not working, oddly.
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.
If this is failing for you locally only (CI doesn't complain), it might be because you're AutoProxxied. There is a bunch of extra A8c DOM that can break the test, so it's a good practice to have the proxxy disabled when running e2e tests. It can be frustrating devex-wise because the TC requires us to be proxxied (so you'll need to toggle the proxxy a lot at times), but I don't think that we should account for the extra DOM in our tests because it's not what the end users see.
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.
Good note of caution. This was an issue that appeared on CI though, and it appears to be a permanent failure.
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.
Yes, I was seeing this exact failure on simple sites; see build 10060993 of
[Gutenberg simple E2E tests edge (desktop)]
as an example. The next build - 10061174 - which included this changeset - passed.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.
The solution failed in the production test site for AT, probably due to the theme? More details in p1684866514069289/1684346413.217409-slack-CDRRDATPS. @worldomonation simplified and fixed it in #77239.