Skip to content

Commit

Permalink
Try fixing flaky E2E test
Browse files Browse the repository at this point in the history
  • Loading branch information
delawski committed Sep 15, 2021
1 parent 2686f36 commit b7af591
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions tests/e2e/specs/admin/amp-options.js
Original file line number Diff line number Diff line change
Expand Up @@ -154,6 +154,7 @@ describe( 'AMP settings screen Review panel', () => {
}

it( 'is present on the page', async () => {
await page.waitForSelector( '.settings-site-review' );
await expect( page ).toMatchElement( 'h2', { text: 'Review' } );
await expect( page ).toMatchElement( 'h3', { text: 'Need help?' } );
await expect( page ).toMatchElement( '.settings-site-review__list li', { text: /support forums/i } );
Expand Down Expand Up @@ -190,6 +191,8 @@ describe( 'AMP settings screen Review panel', () => {
await expect( page ).not.toMatchElement( 'h2', { text: 'Review' } );

await visitAdminPage( 'admin.php', 'page=amp-options' );

await page.waitForSelector( '.settings-site-review' );
await expect( page ).toMatchElement( 'h2', { text: 'Review' } );

await clickMode( 'standard' );
Expand Down

0 comments on commit b7af591

Please sign in to comment.