-
-
Notifications
You must be signed in to change notification settings - Fork 195
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
Showing
14 changed files
with
173 additions
and
206 deletions.
There are no files selected for viewing
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 |
---|---|---|
@@ -1,20 +1,16 @@ | ||
import { testWithMetaMaskMock, MetaMaskMock } from "@synthetixio/synpress"; | ||
import { MetaMaskMock, testWithMetaMaskMock } from '@synthetixio/synpress' | ||
|
||
const test = testWithMetaMaskMock; | ||
const test = testWithMetaMaskMock | ||
|
||
const { expect } = test; | ||
const { expect } = test | ||
|
||
test("should work to the MetaMask Test Dapp", async ({ page }) => { | ||
const metamask = new MetaMaskMock(page); | ||
test('should work to the MetaMask Test Dapp', async ({ page }) => { | ||
const metamask = new MetaMaskMock(page) | ||
Check notice Code scanning / CodeQL Unused variable, import, function or class Note test
Unused variable metamask.
|
||
|
||
await page.goto("/"); | ||
await page.goto('/') | ||
|
||
await expect(page.locator("#accounts")).toHaveText( | ||
"0xd73b04b0e696b0945283defa3eee453814758f1a" | ||
); | ||
await expect(page.locator('#accounts')).toHaveText('0xd73b04b0e696b0945283defa3eee453814758f1a') | ||
|
||
await page.locator("#getAccounts").click(); | ||
await expect(page.locator("#getAccountsResult")).toHaveText( | ||
"0xd73b04b0e696b0945283defa3eee453814758f1a" | ||
); | ||
}); | ||
await page.locator('#getAccounts').click() | ||
await expect(page.locator('#getAccountsResult')).toHaveText('0xd73b04b0e696b0945283defa3eee453814758f1a') | ||
}) |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,18 +1,19 @@ | ||
declare global { | ||
namespace NodeJS { | ||
interface ProcessEnv { | ||
CI: boolean; | ||
HEADLESS: boolean; | ||
CI: boolean | ||
HEADLESS: boolean | ||
} | ||
} | ||
} | ||
|
||
declare global { | ||
interface Window { | ||
ethereum: any; | ||
ethereum: import('ethers').Eip1193Provider | ||
} | ||
|
||
const Web3Mock: any; | ||
// biome-ignore lint/suspicious/noExplicitAny: Web3Mock is a mock object | ||
const Web3Mock: any | ||
} | ||
|
||
export {}; | ||
export {} |
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 |
---|---|---|
@@ -1,3 +1,3 @@ | ||
export * from "./metamask-mock"; | ||
export * from "./utils"; | ||
export * from "./testWithMetaMaskMock"; | ||
export * from './metamask-mock' | ||
export * from './utils' | ||
export * from './testWithMetaMaskMock' |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,11 +1,11 @@ | ||
export type Network = { | ||
name: string; | ||
rpcUrl: string; | ||
chainId: number; | ||
blockExplorerUrl?: string; | ||
name: string | ||
rpcUrl: string | ||
chainId: number | ||
blockExplorerUrl?: string | ||
nativeCurrency?: { | ||
name: string; | ||
symbol: string; | ||
decimals: number; | ||
}; | ||
}; | ||
name: string | ||
symbol: string | ||
decimals: number | ||
} | ||
} |
Oops, something went wrong.