Skip to content

Commit

Permalink
Update e2e tests to account for the changes made to the transitional …
Browse files Browse the repository at this point in the history
…page.
  • Loading branch information
nefeline committed Mar 15, 2024
1 parent 3ff6f27 commit c103c11
Showing 1 changed file with 8 additions and 3 deletions.
Expand Up @@ -48,10 +48,15 @@ describe( 'Transitional', () => {

expect(
screen.getByRole( 'button', {
name: /Preview store/i,
name: /View store/i,
} )
).toBeInTheDocument();

expect(
screen.getByRole( 'button', {
name: /Go to Products/i,
} )
).toBeInTheDocument();
expect(
screen.getByRole( 'button', {
name: /Go to the Editor/i,
Expand All @@ -65,14 +70,14 @@ describe( 'Transitional', () => {
).toBeInTheDocument();
} );

it( 'should record an event when clicking on "Preview store" button', () => {
it( 'should record an event when clicking on "View store" button', () => {
window.open = jest.fn();
// @ts-ignore
render( <Transitional { ...props } /> );

screen
.getByRole( 'button', {
name: /Preview store/i,
name: /View store/i,
} )
.click();

Expand Down

0 comments on commit c103c11

Please sign in to comment.