Skip to content

Commit

Permalink
checked in changes
Browse files Browse the repository at this point in the history
  • Loading branch information
vinayaktorus committed May 9, 2024
1 parent fbb2390 commit 51f0e77
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 1 deletion.
11 changes: 11 additions & 0 deletions walletservices/demo-wallet-services-page/WalletServicesPage.ts
Original file line number Diff line number Diff line change
Expand Up @@ -505,6 +505,17 @@ export class WalletServicesPage {
.textContent()
).toContain(balance);
}

async switchChain(browser: Browser) {
await this.page
.locator(`xpath=.//button[text()='Switch Chain 0xaa36a7']`)
.click();
await delay(5000);
const pages = await browser.contexts()[0].pages();
await pages[1].bringToFront();
await pages[1].locator(`xpath=.//button[text()='Confirm']`).click();
await delay(3000);
}
async verifyWalletInDemoApp(address: string) {
await this.page.locator(`xpath=.//button[text()='Show Wallet']`).click();
await delay(5000);
Expand Down
3 changes: 2 additions & 1 deletion walletservices/demo-wallet-services-page/index.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -81,8 +81,9 @@ test.describe.serial("Wallet Services Scenarios @demo", () => {
await accountsPage.verifyUserInfoInDemoApp(
"[email protected]"
);
await accountsPage.switchChain(browser);
await accountsPage.verifyAddressInDemoApp("0x0dB...d4e49F");
await accountsPage.verifyBalanceInDemoApp("0.199268189999349");
await accountsPage.verifyBalanceInDemoApp("0.635632785708915");
await accountsPage.verifyWalletInDemoApp("0x0dBa...4e49F");
await accountsPage.verifySignedMessages("Personal Sign", browser);
await accountsPage.verifySignedMessages("ETH Sign", browser);
Expand Down

0 comments on commit 51f0e77

Please sign in to comment.