From 1fd2abe6624f99e8e89315fdc73fbdd525b1f31f Mon Sep 17 00:00:00 2001 From: legobt <6wbvkn0j@anonaddy.me> Date: Wed, 9 Oct 2024 00:08:21 +0000 Subject: [PATCH] deps: @metamask/rpc-errors@^6.3.0->^7.0.0 https://github.com/MetaMask/rpc-errors/pull/158 - Update test according to new @metamask/rpc-errors behavior This partially reverts commit aeca6d797fc16d13bcd16f8649159769207ede78. --- app/scripts/lib/createMetaRPCHandler.test.js | 2 +- package.json | 2 +- yarn.lock | 14 ++++++++++++-- 3 files changed, 14 insertions(+), 4 deletions(-) diff --git a/app/scripts/lib/createMetaRPCHandler.test.js b/app/scripts/lib/createMetaRPCHandler.test.js index f39d3dcddeeb..873366d53443 100644 --- a/app/scripts/lib/createMetaRPCHandler.test.js +++ b/app/scripts/lib/createMetaRPCHandler.test.js @@ -70,7 +70,7 @@ describe('createMetaRPCHandler', () => { params: ['bar'], }); streamTest.on('data', (data) => { - expect(data.error.message).toStrictEqual('Internal JSON-RPC error.'); + expect(data.error.message).toStrictEqual('foo-error'); expect(data.error.data.cause.message).toStrictEqual('foo-error'); streamTest.end(); }); diff --git a/package.json b/package.json index 1da07f6c1c18..87f6305542f5 100644 --- a/package.json +++ b/package.json @@ -347,7 +347,7 @@ "@metamask/providers": "^14.0.2", "@metamask/queued-request-controller": "^2.0.0", "@metamask/rate-limit-controller": "^6.0.0", - "@metamask/rpc-errors": "^6.3.0", + "@metamask/rpc-errors": "^7.0.0", "@metamask/safe-event-emitter": "^3.1.1", "@metamask/scure-bip39": "^2.0.3", "@metamask/selected-network-controller": "^18.0.1", diff --git a/yarn.lock b/yarn.lock index d982140250eb..3d74b36c4ebb 100644 --- a/yarn.lock +++ b/yarn.lock @@ -6169,7 +6169,7 @@ __metadata: languageName: node linkType: hard -"@metamask/rpc-errors@npm:^6.0.0, @metamask/rpc-errors@npm:^6.2.1, @metamask/rpc-errors@npm:^6.3.0, @metamask/rpc-errors@npm:^6.3.1": +"@metamask/rpc-errors@npm:^6.0.0, @metamask/rpc-errors@npm:^6.2.1, @metamask/rpc-errors@npm:^6.3.1": version: 6.4.0 resolution: "@metamask/rpc-errors@npm:6.4.0" dependencies: @@ -6179,6 +6179,16 @@ __metadata: languageName: node linkType: hard +"@metamask/rpc-errors@npm:^7.0.0": + version: 7.0.0 + resolution: "@metamask/rpc-errors@npm:7.0.0" + dependencies: + "@metamask/utils": "npm:^9.0.0" + fast-safe-stringify: "npm:^2.0.6" + checksum: 10/f25e2a5506d4d0d6193c88aef8f035ec189a1177f8aee8fa01c9a33d73b1536ca7b5eea2fb33a477768bbd2abaf16529e68f0b3cf714387e5d6c9178225354fd + languageName: node + linkType: hard + "@metamask/safe-event-emitter@npm:^2.0.0": version: 2.0.0 resolution: "@metamask/safe-event-emitter@npm:2.0.0" @@ -26183,7 +26193,7 @@ __metadata: "@metamask/providers": "npm:^14.0.2" "@metamask/queued-request-controller": "npm:^2.0.0" "@metamask/rate-limit-controller": "npm:^6.0.0" - "@metamask/rpc-errors": "npm:^6.3.0" + "@metamask/rpc-errors": "npm:^7.0.0" "@metamask/safe-event-emitter": "npm:^3.1.1" "@metamask/scure-bip39": "npm:^2.0.3" "@metamask/selected-network-controller": "npm:^18.0.1"