Skip to content
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

Try to fix performance test failure on trunk #51407

Merged
merged 5 commits into from
Jun 14, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 11 additions & 7 deletions packages/e2e-tests/specs/performance/site-editor.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -142,17 +142,21 @@ describe( 'Site Editor Performance', () => {
postType: 'page',
} );

// Wait for the first paragraph to be ready.
const firstParagraph = await canvas().waitForXPath(
'//p[contains(text(), "Lorem ipsum dolor sit amet")]'
);
// Wait for the first block to be ready.
await canvas().waitForSelector( '.wp-block' );

// Get inside the post content.
await enterEditMode();

// Insert a new paragraph right under the first one.
await firstParagraph.click(); // Once to select the block overlay.
await firstParagraph.click(); // Once again to select the paragraph.
// Select the post content block wrapper.
await canvas().click( '.wp-block-post-content' );

// Select the first paragraph in the post content block.
const firstParagraph = await canvas().waitForXPath(
'//p[contains(text(), "Lorem ipsum dolor sit amet")]'
);
await firstParagraph.click();

await insertBlock( 'Paragraph' );

// Start tracing.
Expand Down