diff --git a/src/ledger-keyring.test.ts b/src/ledger-keyring.test.ts index 0c61d1c7..edc2e6c5 100644 --- a/src/ledger-keyring.test.ts +++ b/src/ledger-keyring.test.ts @@ -1,6 +1,6 @@ import { Common, Chain, Hardfork } from '@ethereumjs/common'; import { TransactionFactory } from '@ethereumjs/tx'; -import sigUtil from '@metamask/eth-sig-util'; +import * as sigUtil from '@metamask/eth-sig-util'; import EthereumTx from 'ethereumjs-tx'; import * as ethUtil from 'ethereumjs-util'; import HDKey from 'hdkey'; @@ -9,6 +9,14 @@ import { LedgerBridge } from './ledger-bridge'; import { LedgerIframeBridge } from './ledger-iframe-bridge'; import { AccountDetails, LedgerKeyring } from './ledger-keyring'; +jest.mock('@metamask/eth-sig-util', () => { + return { + // eslint-disable-next-line @typescript-eslint/naming-convention + __esModule: true, + ...jest.requireActual('@metamask/eth-sig-util'), + }; +}); + const fakeAccounts = [ '0xF30952A1c534CDE7bC471380065726fa8686dfB3', '0x44fe3Cf56CaF651C4bD34Ae6dbcffa34e9e3b84B',