Skip to content

Commit

Permalink
Update integration tests after adding new supported networks
Browse files Browse the repository at this point in the history
As a support for two new networks was added, we need to update tests that assert
the number of supported networks.
  • Loading branch information
michalinacienciala committed Sep 25, 2023
1 parent 912b0c5 commit a194ea6
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions background/services/chain/tests/index.integration.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -197,17 +197,17 @@ describe("ChainService", () => {
it("Should properly update supported networks", async () => {
chainService.supportedNetworks = []
await chainService.updateSupportedNetworks()
expect(chainService.supportedNetworks.length).toBe(8)
expect(chainService.supportedNetworks.length).toBe(10)
})
})

describe("addCustomChain", () => {
// prettier-ignore
const FANTOM_CHAIN_PARAMS = { chainId: "250", blockExplorerUrl: "https://ftmscan.com", chainName: "Fantom Opera", nativeCurrency: { name: "Fantom", symbol: "FTM", decimals: 18, }, rpcUrls: [ "https://fantom-mainnet.gateway.pokt.network/v1/lb/62759259ea1b320039c9e7ac", "https://rpc.ftm.tools", "https://rpc.ankr.com/fantom", "https://rpc.fantom.network", "https://rpc2.fantom.network", "https://rpc3.fantom.network", "https://rpcapi.fantom.network", "https://fantom-mainnet.public.blastapi.io", "https://1rpc.io/ftm", ], blockExplorerUrls: ["https://ftmscan.com"], }
it("should update supported networks after adding a chain", async () => {
expect(chainService.supportedNetworks.length).toBe(8)
expect(chainService.supportedNetworks.length).toBe(10)
await chainService.addCustomChain(FANTOM_CHAIN_PARAMS)
expect(chainService.supportedNetworks.length).toBe(9)
expect(chainService.supportedNetworks.length).toBe(11)
})

it("should create a provider for the new chain", async () => {
Expand Down

0 comments on commit a194ea6

Please sign in to comment.