-
Notifications
You must be signed in to change notification settings - Fork 36
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
6ae83e5
commit 8d32c98
Showing
9 changed files
with
85 additions
and
72 deletions.
There are no files selected for viewing
29 changes: 29 additions & 0 deletions
29
packages/e2e-tests/src/assert/multidelegation/SwitchingPoolModalAssert.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
import SwitchingStakePoolModal from '../../elements/multidelegation/SwitchingStakePoolModal'; | ||
import { expect } from 'chai'; | ||
import { t } from '../../utils/translationService'; | ||
|
||
class SwitchingPoolModalAssert { | ||
assertSeeSwitchingPoolModal = async (shouldBeVisible: boolean) => { | ||
await SwitchingStakePoolModal.title.waitForDisplayed({ reverse: !shouldBeVisible }); | ||
await SwitchingStakePoolModal.description.waitForDisplayed({ reverse: !shouldBeVisible }); | ||
await SwitchingStakePoolModal.cancelButton.waitForDisplayed({ reverse: !shouldBeVisible }); | ||
await SwitchingStakePoolModal.fineByMeButton.waitForDisplayed({ reverse: !shouldBeVisible }); | ||
|
||
if (shouldBeVisible) { | ||
expect(await SwitchingStakePoolModal.title.getText()).to.equal( | ||
await t('modals.poolsManagement.title', 'staking') | ||
); | ||
expect(await SwitchingStakePoolModal.description.getText()).to.equal( | ||
await t('modals.poolsManagement.description.adjustment', 'staking') | ||
); | ||
expect(await SwitchingStakePoolModal.cancelButton.getText()).to.equal( | ||
await t('modals.poolsManagement.buttons.cancel', 'staking') | ||
); | ||
expect(await SwitchingStakePoolModal.fineByMeButton.getText()).to.equal( | ||
await t('modals.poolsManagement.buttons.confirm', 'staking') | ||
); | ||
} | ||
}; | ||
} | ||
|
||
export default new SwitchingPoolModalAssert(); |
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters