Skip to content

Commit

Permalink
Remove unnecessary console.warn statements added in #9121
Browse files Browse the repository at this point in the history
  • Loading branch information
anu-rock committed Aug 9, 2024
1 parent 28a3248 commit 4120820
Show file tree
Hide file tree
Showing 7 changed files with 7 additions and 36 deletions.
6 changes: 1 addition & 5 deletions tests/e2e/config/jest.setup.js
Original file line number Diff line number Diff line change
Expand Up @@ -136,11 +136,7 @@ beforeAll( async () => {

capturePageEventsForTearDown();
page.on( 'dialog', async function ( dialog ) {
try {
await dialog.accept();
} catch ( err ) {
console.warn( err.message );
}
await dialog.accept();
} );
setTestTimeouts();
await setupBrowser();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -62,11 +62,7 @@ describeif( RUN_SUBSCRIPTIONS_TESTS )(
afterAll( async () => {
page.removeAllListeners( 'dialog' );
page.on( 'dialog', async function ( dialog ) {
try {
await dialog.accept();
} catch ( err ) {
console.warn( err.message );
}
await dialog.accept();
} );
await merchant.logout();
} );
Expand All @@ -91,11 +87,7 @@ describeif( RUN_SUBSCRIPTIONS_TESTS )(
page.removeAllListeners( 'dialog' ),
evalAndClick( 'button.save_order' ),
page.on( 'dialog', async ( dialog ) => {
try {
await dialog.accept();
} catch ( err ) {
console.warn( err.message );
}
await dialog.accept();
} ),
uiUnblocked(),
page.waitForNavigation( { waitUntil: 'networkidle0' } ),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -64,11 +64,7 @@ describe( 'Disputes > Submit winning dispute', () => {
afterAll( async () => {
page.removeAllListeners( 'dialog' );
page.on( 'dialog', async function ( dialog ) {
try {
await dialog.accept();
} catch ( err ) {
console.warn( err.message );
}
await dialog.accept();
} );
await merchant.logout();
} );
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -56,11 +56,7 @@ describe( 'Order > Full refund', () => {
afterAll( async () => {
page.removeAllListeners( 'dialog' );
page.on( 'dialog', async function ( dialog ) {
try {
await dialog.accept();
} catch ( err ) {
console.warn( err.message );
}
await dialog.accept();
} );
await merchant.logout();
} );
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -89,11 +89,7 @@ describe.each( dataTable )(
afterEach( async () => {
page.removeAllListeners( 'dialog' );
page.on( 'dialog', async function ( dialog ) {
try {
await dialog.accept();
} catch ( err ) {
console.warn( err.message );
}
await dialog.accept();
} );
} );

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -57,11 +57,7 @@ describe( 'Order > Refund Failure', () => {
afterAll( async () => {
page.removeAllListeners( 'dialog' );
page.on( 'dialog', async function ( dialog ) {
try {
await dialog.accept();
} catch ( err ) {
console.warn( err.message );
}
await dialog.accept();
} );
await merchant.logout();
} );
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -132,7 +132,6 @@ describe( 'Klarna checkout', () => {
} );
readyToBuy = true;
} catch ( err ) {
console.warn( err );
readyToBuy = false;
}

Expand Down

0 comments on commit 4120820

Please sign in to comment.