-
Notifications
You must be signed in to change notification settings - Fork 4.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
Migrate remaining 'block switcher' e2e tests to Playwright #57381
Conversation
await page.keyboard.type( '## I am a header' ); | ||
await page.keyboard.down( 'Shift' ); | ||
await page.keyboard.press( 'ArrowUp' ); | ||
await page.keyboard.up( 'Shift' ); |
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.
Note for future me: If this fails again, ensure the block toolbar is displayed by adding await pageUtils.pressKeys( 'alt+F10' );
.
Currently, I can reproduce the scenario with Playwright, but I can do it manually sometimes.
Size Change: +159 B (0%) Total Size: 1.69 MB
ℹ️ View Unchanged
|
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.
LGTM 👍
Although I suggested a small change, I ran this test in debug mode and confirmed that the test worked correctly.
BTW I learned that this test migration was also attempted in #50845. How about adding him as a co-author?
await createNewPost(); | ||
} ); | ||
|
||
it( 'Should show the expected block transforms on the list block when the blocks are removed', async () => { |
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.
How about making "Should" a lower case along with other tests?
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 it's okay. We don't really have a strict guideline when it comes to naming.
.getByRole( 'menuitem', { name: 'Columns' } ) | ||
).toBeHidden(); | ||
} ); | ||
|
||
test( 'Block variation transforms', async ( { editor, page } ) => { | ||
// This is the `stack` Group variation. |
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.
// This is the `stack` Group variation. | |
// This is the `flex` Group variation. |
This looks like a typo.
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 don't think so; the variation name is stack
. The flex is just implementation details.
Co-authored-by: Pavan Patil <[email protected]>
What?
Part of #38851.
PR migrates
block-switcher.test.js
e2e tests to Playwright.Why?
The test has been failing a lot recently. Ref: #40369.
Testing Instructions