Skip to content

Commit 64ff7cd

Browse files
authored
test(extension): test automation maintenance (#723)
1 parent 39792b1 commit 64ff7cd

File tree

7 files changed

+14
-8
lines changed

7 files changed

+14
-8
lines changed

packages/e2e-tests/src/assert/drawerSendExtendedAssert.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -362,7 +362,7 @@ class DrawerSendExtendedAssert {
362362

363363
async assertSeeSearchLoader(shouldBeDisplayed: boolean) {
364364
const addressInput = new AddressInput();
365-
await addressInput.searchLoader.waitForDisplayed({ reverse: !shouldBeDisplayed });
365+
await addressInput.searchLoader.waitForDisplayed({ reverse: !shouldBeDisplayed, interval: 150 });
366366
}
367367

368368
async assertAddressBookButtonEnabled(bundleIndex: number, shouldBeEnabled: boolean) {

packages/e2e-tests/src/assert/multidelegation/MultidelegationPageAssert.ts

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,9 @@ class MultidelegationPageAssert {
4343
expect(await MultidelegationPage.delegationCardBalanceLabel.getText()).to.equal(
4444
await t('overview.delegationCard.label.balance', 'staking')
4545
);
46-
const adaValue = Number((await MultidelegationPage.delegationCardBalanceValue.getText()).split(' ')[0]);
46+
const adaValue = Number(
47+
(await MultidelegationPage.delegationCardBalanceValue.getText()).split(' ')[0].replace(',', '')
48+
);
4749
expect(adaValue).to.be.greaterThan(0);
4850
expect(await MultidelegationPage.delegationCardPoolsLabel.getText()).to.equal(
4951
await t('overview.delegationCard.label.pools', 'staking')

packages/e2e-tests/src/elements/transactionsPage.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -101,7 +101,7 @@ class TransactionsPage {
101101
let rowIndex = 0;
102102
while (rowIndex < tokensCounterValue && (await this.rows).length < tokensCounterValue) {
103103
await this.scrollToTheRow(rowIndex);
104-
rowIndex += 8;
104+
rowIndex += 7;
105105
await browser.pause(1000);
106106
}
107107
}

packages/e2e-tests/src/features/MultidelegationDelegatedFundsPopup.feature

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,11 @@
11
@Multidelegation-DelegatedFunds-Popup @Testnet @Mainnet
22
Feature: Staking Page - Popup View
33

4-
Background:
5-
Given Lace is ready for test
6-
74
@LW-8330
85
Scenario Outline: Popup View - Delegation card displays correct data
96
Given I open wallet: "<walletName>" in: popup mode
107
And I disable showing Multidelegation beta banner
8+
And I disable showing Multidelegation persistence banner
119
When I navigate to Staking popup page
1210
Then I see Delegation title displayed for multidelegation
1311
And I see Delegation card displaying correct data
@@ -20,6 +18,7 @@ Feature: Staking Page - Popup View
2018
Scenario Outline: Popup View - Delegated pools cards are present
2119
Given I open wallet: "<walletName>" in: popup mode
2220
And I disable showing Multidelegation beta banner
21+
And I disable showing Multidelegation persistence banner
2322
When I navigate to Staking popup page
2423
And I see Delegation pool cards are displayed for popup view
2524
Examples:
@@ -29,7 +28,8 @@ Feature: Staking Page - Popup View
2928

3029
@LW-8480
3130
Scenario Outline: Popup View - Staking - Hover over currently staking element: <element>
32-
Given I disable showing Multidelegation beta banner
31+
Given Lace is ready for test
32+
And I disable showing Multidelegation beta banner
3333
And I navigate to Staking popup page
3434
When I hover over <element> in currently staking component
3535
Then I see tooltip for element in currently staking component

packages/e2e-tests/src/features/TransactionsPopup.feature

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ Feature: Transactions - Popup view
2323
Scenario: Popup View - Infinite scroll
2424
When I navigate to Transactions popup page
2525
And Transactions section is displayed
26-
And I scroll to the row: 8
26+
And I scroll to the row: 7
2727
Then a skeleton is displayed at the bottom of the page
2828

2929
@LW-2545 @Testnet

packages/e2e-tests/src/steps/commonSteps.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -145,6 +145,8 @@ Then(/^I open wallet: "([^"]*)" in: (extended|popup) mode$/, async (walletName:
145145
await localStorageManager.cleanLocalStorage();
146146
await localStorageInitializer.initializeWallet(walletName);
147147
await browser.refresh();
148+
await settingsExtendedPageObject.waitUntilSyncingModalDisappears();
149+
await settingsExtendedPageObject.closeWalletSyncedToast();
148150
await topNavigationAssert.assertLogoPresent();
149151
await mainMenuPageObject.navigateToSection('Tokens', mode);
150152
});

packages/e2e-tests/src/steps/onboardingSteps.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,7 @@ import CommonAssert from '../assert/commonAssert';
3838
import { shuffle } from '../utils/arrayUtils';
3939
import OnboardingConnectHardwareWalletPage from '../elements/onboarding/connectHardwareWalletPage';
4040
import SelectAccountPage from '../elements/onboarding/selectAccountPage';
41+
import { browser } from '@wdio/globals';
4142

4243
const mnemonicWords: string[] = getTestWallet(TestWalletName.TestAutomationWallet).mnemonic ?? [];
4344
const invalidMnemonicWords: string[] = getTestWallet(TestWalletName.InvalidMnemonic).mnemonic ?? [];
@@ -109,6 +110,7 @@ When(
109110
/^I click "(Cancel|OK)" button on "(Limited support for DApp|Restoring a multi-address wallet\?|Are you sure you want to start again\?)" modal$/,
110111
// eslint-disable-next-line no-unused-vars,@typescript-eslint/no-unused-vars
111112
async (button: 'Cancel' | 'OK', _modalType: string) => {
113+
await browser.pause(500);
112114
switch (button) {
113115
case 'Cancel':
114116
await Modal.cancelButton.click();

0 commit comments

Comments
 (0)