Skip to content

Commit

Permalink
chore: Fix createSignerFactory test
Browse files Browse the repository at this point in the history
  • Loading branch information
janjakubnanista committed Nov 30, 2023
1 parent 34f24e4 commit 52dde80
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions packages/utils-evm-hardhat/test/signer.test.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
import chai from 'chai'
import chaiAsPromised from 'chai-as-promised'
import { expect } from 'chai'
import hre from 'hardhat'
import { EndpointId } from '@layerzerolabs/lz-definitions'
import { createSignerFactory } from '../src/signer'
import { JsonRpcSigner, Web3Provider } from '@ethersproject/providers'
Expand All @@ -11,11 +10,11 @@ chai.use(chaiAsPromised)
describe('signer', () => {
describe('createSignerFactory', () => {
it('should reject with an endpoint that is not in the hardhat config', async () => {
await expect(createSignerFactory(hre)(EndpointId.CATHAY_TESTNET)).to.eventually.be.rejected
await expect(createSignerFactory()(EndpointId.CATHAY_TESTNET)).to.eventually.be.rejected
})

it('should return a JsonRpcSigner', async () => {
const signer = await createSignerFactory(hre)(EndpointId.ETHEREUM_MAINNET)
const signer = await createSignerFactory()(EndpointId.ETHEREUM_MAINNET)

expect(signer).to.be.instanceOf(JsonRpcSigner)
expect(signer.provider).to.be.instanceOf(Web3Provider)
Expand Down

0 comments on commit 52dde80

Please sign in to comment.