Skip to content

Commit

Permalink
Updating e2e test selectors
Browse files Browse the repository at this point in the history
  • Loading branch information
ramonjd committed Oct 15, 2021
1 parent 91fa9b2 commit 1671519
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 6 deletions.
2 changes: 1 addition & 1 deletion packages/e2e-tests/specs/editor/blocks/cover.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ describe( 'Cover', () => {
// Select the cover block.By default the child paragraph gets selected.
await page.click( '.edit-post-header-toolbar__list-view-toggle' );
await page.click(
'.block-editor-list-view-block__contents-container button'
'.block-editor-list-view-block__contents-container a'
);

const heightInput = (
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ describe( 'Navigating the block hierarchy', () => {
await page.click( '.edit-post-header-toolbar__list-view-toggle' );
const columnsBlockMenuItem = (
await page.$x(
"//button[contains(@class,'block-editor-list-view-block-select-button') and contains(text(), 'Columns')]"
"//a[contains(@class,'block-editor-list-view-block-select-button') and contains(text(), 'Columns')]"
)
)[ 0 ];
await columnsBlockMenuItem.click();
Expand All @@ -75,7 +75,7 @@ describe( 'Navigating the block hierarchy', () => {
// Navigate to the last column block.
const lastColumnsBlockMenuItem = (
await page.$x(
"//button[contains(@class,'block-editor-list-view-block-select-button') and contains(text(), 'Column')]"
"//a[contains(@class,'block-editor-list-view-block-select-button') and contains(text(), 'Column')]"
)
)[ 3 ];
await lastColumnsBlockMenuItem.click();
Expand Down Expand Up @@ -188,7 +188,7 @@ describe( 'Navigating the block hierarchy', () => {
await page.click( '.edit-post-header-toolbar__list-view-toggle' );
const groupMenuItem = (
await page.$x(
"//button[contains(@class,'block-editor-list-view-block-select-button') and contains(text(), 'Group')]"
"//a[contains(@class,'block-editor-list-view-block-select-button') and contains(text(), 'Group')]"
)
)[ 0 ];
await groupMenuItem.click();
Expand Down
4 changes: 2 additions & 2 deletions packages/e2e-tests/specs/editor/various/list-view.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -42,12 +42,12 @@ describe( 'List view', () => {
await pressKeyWithModifier( 'access', 'o' );

const paragraphBlock = await page.waitForXPath(
'//button[contains(., "Paragraph")][@draggable="true"]'
'//a[contains(., "Paragraph")][@draggable="true"]'
);

// Drag above the heading block
const headingBlock = await page.waitForXPath(
'//button[contains(., "Heading")][@draggable="true"]'
'//a[contains(., "Heading")][@draggable="true"]'
);

await dragAndDrop( paragraphBlock, headingBlock, -5 );
Expand Down

0 comments on commit 1671519

Please sign in to comment.