From 10076246f9b54d335ade637292d5137f494ec0a8 Mon Sep 17 00:00:00 2001 From: Boyu Yang Date: Mon, 4 Sep 2023 20:53:39 +0800 Subject: [PATCH] fix: catch the latest version of Axon --- test/rpc/eth_call.test.js | 2 +- test/rpc/eth_estimateGas.test.js | 2 +- test/rpc/web3_sha3.test.js | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/test/rpc/eth_call.test.js b/test/rpc/eth_call.test.js index 384e62f..c88ac5c 100644 --- a/test/rpc/eth_call.test.js +++ b/test/rpc/eth_call.test.js @@ -418,7 +418,7 @@ describe("eth_call", function () { data: '', }, 'latest']); } catch (error) { - expect(error.message).to.include('invalid prefix'); + expect(error.message).to.include('Hex should start with 0x'); } }) it("data is 0x0fff,should return 0x", async () => { diff --git a/test/rpc/eth_estimateGas.test.js b/test/rpc/eth_estimateGas.test.js index d070aee..3a55034 100644 --- a/test/rpc/eth_estimateGas.test.js +++ b/test/rpc/eth_estimateGas.test.js @@ -410,7 +410,7 @@ describe("eth_estimateGas", function () { data: '', }]) } catch (error) { - expect(error.message).to.include('invalid prefix'); + expect(error.message).to.include('Hex should start with 0x'); } }) it("data is 0x0fff,should return gas cost", async () => { diff --git a/test/rpc/web3_sha3.test.js b/test/rpc/web3_sha3.test.js index 7f34409..9f0dd4c 100644 --- a/test/rpc/web3_sha3.test.js +++ b/test/rpc/web3_sha3.test.js @@ -32,7 +32,7 @@ describe("web3_sha3", function () { try { await ethers.provider.send('web3_sha3', ["68656c6c6f20776f726c64"]) } catch (error) { - expect(error.message).to.include('invalid prefix'); + expect(error.message).to.include('Hex should start with 0x'); } }) })