Skip to content

Commit

Permalink
fixes synpress startup error and the Login test
Browse files Browse the repository at this point in the history
  • Loading branch information
Administrator authored and RakeshUP committed Nov 16, 2023
1 parent 9e01c8a commit f22cc76
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 3 deletions.
16 changes: 14 additions & 2 deletions tests/e2e/pages/LoginComponent.ts
Original file line number Diff line number Diff line change
@@ -1,8 +1,20 @@
export default class ConnectComponent {
/** Actions to connect Metamask wallet to app */
connectMetamask() {
cy.get('nav button').click();
cy.get('.web3modal-provider-wrapper').first().click();
cy.get('nav button:last').click();
cy.get('w3m-modal')
.shadow()
.find('w3m-modal-router')
.shadow()
.find('w3m-connect-wallet-view')
.shadow()
.find('w3m-desktop-wallet-selection')
.shadow()
.find('w3m-wallet-button[name="MetaMask"')
.shadow()
.find('button')
.click();
cy.wait(1000);
cy.switchToMetamaskWindow();
cy.acceptMetamaskAccess().should('be.true');
cy.switchToCypressWindow();
Expand Down
2 changes: 1 addition & 1 deletion tests/e2e/tsconfig.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"compilerOptions": {
"allowJs": true,
"baseUrl": "../../node_modules",
"baseUrl": "./",
"types": [
"cypress",
"@synthetixio/synpress/support",
Expand Down

0 comments on commit f22cc76

Please sign in to comment.