Files
safe-wallet/apps/web/cypress/e2e/regression/multichain_create_safe_flow.cy.js
VaryaandGitHub 69b7318abe fix(tests): Adjust Cypress tests to the latest UI changes (#8248)
* fix: copilot tests: remove overlapping element

* fix: tx_history_4 tests: adjust tests to the latest UI

* fix: tx_history and tx_history_2 tests adjusted to the new ui

* refactor: replace  the data-fragile Cypress E2E with unit tests for the "Safe App tx shows icon + name" behavior

* refactor: adjust Proposers test to the latest UI changes

* refactor: adjust batch_tx tests to the latest ui changes

* refactor: adjust safe creation tests to the latest ui changes

* refactor: adjust tx creation tests to the latest ui changes

* refactor: adjust multichain setup tests to the latest ui changes

* fix: correct string text in the Proposers test

* fix: swap link as per FF

* fix: multichain creation (add a login step; block overlapping beamer)

* chore: bring back the swap prod link

* fix: relay test: use sepolia instead of polygon

* fix: proposers test assertion

* feat: harden the CF tests assertions to distinct newly created safes from existing in the space

* fix: add missing login step to the Multichain Create Safe Flow tests

* feat: add a page function to use the old UI

* chore: remove obsolete healthcheck Cypress tests; adjust comments

* fix: harden the token tests (get token name + value separately from a cell instead of full row); compare both

* fix: adjust swap test with a blocked recipient to the cow widget changes

* refactor: replace browser permission e2e tests with unit / component tests

* fix: recovery tests: bypass Spaces login by setting a classic UI session storage key

* fix: bring back the Custom Recipient logic for swap tests

* fix: flaky multichain network tests
2026-07-08 12:35:54 +02:00

55 lines
2.4 KiB
JavaScript

import * as constants from '../../support/constants.js'
import * as main from '../pages/main.page.js'
import * as wallet from '../../support/utils/wallet.js'
import * as createwallet from '../pages/create_wallet.pages.js'
import * as owner from '../pages/owners.pages.js'
import { getMockAddress } from '../../support/utils/ethers.js'
const walletCredentials = JSON.parse(Cypress.env('CYPRESS_WALLET_CREDENTIALS'))
const signer = walletCredentials.OWNER_4_PRIVATE_KEY
describe('Multichain safe creation flow tests', () => {
beforeEach(() => {
createwallet.startCreateSafeFlow(signer)
})
it('Verify Review screen for multichain safe creation flow', () => {
createwallet.selectMultiNetwork(1, constants.networks.polygon.toLowerCase())
createwallet.clickOnYourSafeAccountPreview()
createwallet.clickOnNextBtn()
createwallet.clickOnNextBtn()
main.verifyElementsExist([
createwallet.payNowLaterMessageBox,
createwallet.safeSetupOverview,
createwallet.networksLogoList,
createwallet.reviewStepOwnerInfo,
createwallet.reviewStepSafeName,
createwallet.reviewStepThreshold,
createwallet.reviewStepNextBtn,
])
createwallet.checkNetworkLogoInReviewStep([constants.networkKeys.polygon, constants.networkKeys.sepolia])
})
it('Verify that selected networks are displayed in preview multichain safe', () => {
createwallet.selectMultiNetwork(1, constants.networks.polygon.toLowerCase())
createwallet.clickOnYourSafeAccountPreview()
createwallet.clickOnNextBtn()
createwallet.clickOnNextBtn()
createwallet.checkNetworkLogoInReviewStep([constants.networkKeys.polygon, constants.networkKeys.sepolia])
})
it('Verify Success safe creation screen for multichain creation', () => {
createwallet.selectMultiNetwork(1, constants.networks.polygon.toLowerCase())
createwallet.clickOnYourSafeAccountPreview()
createwallet.clickOnNextBtn()
owner.clickOnAddSignerBtn()
owner.typeOwnerAddressCreateSafeStep(1, getMockAddress())
createwallet.clickOnNextBtn()
createwallet.clickOnSignInToWorkspaceBtn()
createwallet.clickOnReviewStepNextBtn()
main.verifyElementsExist([createwallet.cfSafeActivationMsg, createwallet.cfSafeCreationSuccessMsg])
createwallet.checkNetworkLogoInSafeCreationModal([constants.networkKeys.polygon, constants.networkKeys.sepolia])
createwallet.clickOnLetsGoBtn()
})
})