Skip to content
This repository has been archived by the owner on Oct 7, 2024. It is now read-only.

Commit

Permalink
devDeps: ethereumjs-wallet@^1.0.2 -> @ethereumjs/wallet@^2.0.0 (#263)
Browse files Browse the repository at this point in the history
  • Loading branch information
legobeat authored Sep 12, 2023
1 parent 63e7a16 commit e4c6e2a
Show file tree
Hide file tree
Showing 3 changed files with 64 additions and 411 deletions.
6 changes: 1 addition & 5 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,7 @@
"@metamask/utils": "^8.1.0"
},
"devDependencies": {
"@ethereumjs/wallet": "^2.0.0",
"@lavamoat/allow-scripts": "^2.3.1",
"@lavamoat/preinstall-always-fail": "^1.0.0",
"@metamask/auto-changelog": "^3.0.0",
Expand All @@ -67,7 +68,6 @@
"eslint-plugin-jsdoc": "^40.0.3",
"eslint-plugin-node": "^11.1.0",
"eslint-plugin-prettier": "^4.2.1",
"ethereumjs-wallet": "^1.0.2",
"jest": "^29.0.0",
"jest-it-up": "^2.0.2",
"prettier": "^2.8.1",
Expand All @@ -90,10 +90,6 @@
"lavamoat": {
"allowScripts": {
"@lavamoat/preinstall-always-fail": false,
"eth-sig-util>ethereumjs-util>keccak": false,
"eth-sig-util>ethereumjs-util>secp256k1": false,
"ethereumjs-wallet>ethereum-cryptography>keccak": false,
"ethereumjs-wallet>ethereum-cryptography>secp256k1": false,
"@metamask/eth-hd-keyring>eth-simple-keyring>eth-sig-util>ethereumjs-util>keccak": false,
"@metamask/eth-hd-keyring>eth-simple-keyring>eth-sig-util>ethereumjs-util>secp256k1": false
}
Expand Down
5 changes: 3 additions & 2 deletions src/KeyringController.test.ts
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
import { Wallet } from '@ethereumjs/wallet';
import HdKeyring from '@metamask/eth-hd-keyring';
import { normalize as normalizeAddress } from '@metamask/eth-sig-util';
import type { Hex } from '@metamask/utils';
import { bytesToHex } from '@metamask/utils';
import { strict as assert } from 'assert';
import Wallet from 'ethereumjs-wallet';
import * as sinon from 'sinon';

import { KeyringController, keyringBuilderFactory } from '.';
Expand Down Expand Up @@ -860,7 +861,7 @@ describe('KeyringController', () => {
);

const wallet = Wallet.fromPrivateKey(Buffer.from(privateAppKey, 'hex'));
const recoveredAddress = `0x${wallet.getAddress().toString('hex')}`;
const recoveredAddress = bytesToHex(wallet.getAddress());

expect(recoveredAddress).toBe(appKeyAddress);
expect(privateAppKey).not.toBe(privateKey);
Expand Down
Loading

0 comments on commit e4c6e2a

Please sign in to comment.