From 822873775046970706164a53e94c833bcd3ff296 Mon Sep 17 00:00:00 2001 From: Bartek Date: Thu, 19 Dec 2024 17:05:57 +0100 Subject: [PATCH] fixes --- packages/arb-token-bridge-ui/synpress.config.ts | 3 ++- .../arb-token-bridge-ui/tests/e2e/specs/approveToken.cy.ts | 2 +- .../arb-token-bridge-ui/tests/e2e/specs/withdrawERC20.cy.ts | 4 ++-- .../tests/e2e/specs/withdrawNativeToken.cy.ts | 4 ++-- 4 files changed, 7 insertions(+), 6 deletions(-) diff --git a/packages/arb-token-bridge-ui/synpress.config.ts b/packages/arb-token-bridge-ui/synpress.config.ts index 84a332c1b0..31ae417ba1 100644 --- a/packages/arb-token-bridge-ui/synpress.config.ts +++ b/packages/arb-token-bridge-ui/synpress.config.ts @@ -226,7 +226,8 @@ export default defineConfig({ }, baseUrl: 'http://localhost:3000', specPattern: tests, - supportFile: 'tests/support/index.ts' + supportFile: 'tests/support/index.ts', + defaultCommandTimeout: 20_000 } }) diff --git a/packages/arb-token-bridge-ui/tests/e2e/specs/approveToken.cy.ts b/packages/arb-token-bridge-ui/tests/e2e/specs/approveToken.cy.ts index c96ceb903c..896ce9c954 100644 --- a/packages/arb-token-bridge-ui/tests/e2e/specs/approveToken.cy.ts +++ b/packages/arb-token-bridge-ui/tests/e2e/specs/approveToken.cy.ts @@ -50,7 +50,7 @@ describe('Approve token for deposit', () => { * If confirm spending fails, test is still considered to be passing by Cypress * We add another check to make sure the test fails if needed */ - cy.wait(10_000) + cy.wait(25_000) cy.rejectMetamaskTransaction() }) }) diff --git a/packages/arb-token-bridge-ui/tests/e2e/specs/withdrawERC20.cy.ts b/packages/arb-token-bridge-ui/tests/e2e/specs/withdrawERC20.cy.ts index a1ac1fb75e..e75600cfe4 100644 --- a/packages/arb-token-bridge-ui/tests/e2e/specs/withdrawERC20.cy.ts +++ b/packages/arb-token-bridge-ui/tests/e2e/specs/withdrawERC20.cy.ts @@ -103,7 +103,7 @@ describe('Withdraw ERC20 Token', () => { }) context('should show clickable withdraw button', () => { - cy.findMoveFundsButton().click() + cy.startTransfer() }) context('should withdraw successfully', () => { @@ -218,7 +218,7 @@ describe('Withdraw ERC20 Token', () => { }) context('should show clickable withdraw button', () => { - cy.findMoveFundsButton().click() + cy.startTransfer() }) context('should initiate withdrawal successfully', () => { diff --git a/packages/arb-token-bridge-ui/tests/e2e/specs/withdrawNativeToken.cy.ts b/packages/arb-token-bridge-ui/tests/e2e/specs/withdrawNativeToken.cy.ts index 5de34a32de..5f3693284e 100644 --- a/packages/arb-token-bridge-ui/tests/e2e/specs/withdrawNativeToken.cy.ts +++ b/packages/arb-token-bridge-ui/tests/e2e/specs/withdrawNativeToken.cy.ts @@ -61,7 +61,7 @@ describe('Withdraw native token', () => { ETHToWithdraw = Number((Math.random() * 0.001).toFixed(5)) // generate a new withdrawal amount for each test-run attempt so that findAllByText doesn't stall coz of prev transactions cy.login({ networkType: 'childChain' }) cy.typeAmount(ETHToWithdraw) - cy.findMoveFundsButton().click() + cy.startTransfer() cy.findByText(/Arbitrum’s bridge/i).should('be.visible') // the Continue withdrawal button should be disabled at first @@ -146,7 +146,7 @@ describe('Withdraw native token', () => { cy.typeAmount(ETHToWithdraw) cy.fillCustomDestinationAddress() - cy.findMoveFundsButton().click() + cy.startTransfer() cy.findByText(/Arbitrum’s bridge/i).should('be.visible') // the Continue withdrawal button should be disabled at first