Skip to content

Commit

Permalink
test: fix unlockHardwareWalletAccount addNewAccount mock
Browse files Browse the repository at this point in the history
  • Loading branch information
mikesposito committed Sep 27, 2023
1 parent 5f8b71e commit 3d7823d
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions app/scripts/metamask-controller.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -730,11 +730,12 @@ describe('MetaMaskController', () => {
describe('unlockHardwareWalletAccount', () => {
const accountToUnlock = 10;
beforeEach(async () => {
await metamaskController.createNewVaultAndKeychain('password');

jest.spyOn(window, 'open').mockReturnValue();
jest
.spyOn(metamaskController.coreKeyringController, 'addNewAccount')
.spyOn(
metamaskController.coreKeyringController,
'addNewAccountForKeyring',
)
.mockReturnValue('0x123');

jest
Expand Down

0 comments on commit 3d7823d

Please sign in to comment.