Skip to content

Commit

Permalink
✨ feat: Cypress integration with EthereumWalletMock (#1133)
Browse files Browse the repository at this point in the history
* feat: Cypress config files

* feat: cypress for mocked wallet - basics

* feat: Cypress with mocked ethereum wallet

* fix: dependencies

* fix: cleanup

* fix: clean imports

* fix: testing path

* fix
  • Loading branch information
matstyler authored May 29, 2024
1 parent df46224 commit 85ba843
Show file tree
Hide file tree
Showing 32 changed files with 866 additions and 30 deletions.
13 changes: 13 additions & 0 deletions packages/core/src/cypress/ensureRdpPort.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
export default function ensureRdpPort(args: string[]) {
const existing = args.find((arg) => arg.slice(0, 23) === '--remote-debugging-port')

if (existing) {
return Number(existing.split('=')[1])
}

const port = 40000 + Math.round(Math.random() * 25000)

args.push(`--remote-debugging-port=${port}`)

return port
}
1 change: 1 addition & 0 deletions packages/core/src/cypress/index.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
export { default as ensureRdpPort } from './ensureRdpPort'
1 change: 1 addition & 0 deletions packages/core/src/index.ts
Original file line number Diff line number Diff line change
@@ -1 +1,2 @@
export { default as testWithSynpress } from './testWithSynpress'
export * from './cypress'
Loading

0 comments on commit 85ba843

Please sign in to comment.