From 17f2f159052ff2efc63165ac31e93f61a21db553 Mon Sep 17 00:00:00 2001 From: kourin Date: Wed, 11 Dec 2024 00:35:27 +0900 Subject: [PATCH] Add timeout for some failing tests --- e2e_test/js-tests/test_ethers_tx.mjs | 10 +++++----- e2e_test/run_all_tests.sh | 2 ++ 2 files changed, 7 insertions(+), 5 deletions(-) diff --git a/e2e_test/js-tests/test_ethers_tx.mjs b/e2e_test/js-tests/test_ethers_tx.mjs index 3faf2d9cdf..5cffdb9f69 100644 --- a/e2e_test/js-tests/test_ethers_tx.mjs +++ b/e2e_test/js-tests/test_ethers_tx.mjs @@ -12,7 +12,7 @@ describe("ethers.js send tx", () => { value: 1, }); const receipt = await tx.wait(); - }).timeout(10_000); + }).timeout(20_000); }); describe("ethers.js compatibility tests with state", () => { @@ -22,7 +22,7 @@ describe("ethers.js compatibility tests with state", () => { // These assertions trigger on undefined or null assert.notEqual(block, null); assert.notEqual(block.gasLimit, null); - }); + }) it("EIP-1559 transactions supported (can get feeData)", async () => { const feeData = await provider.getFeeData(); @@ -32,7 +32,7 @@ describe("ethers.js compatibility tests with state", () => { assert.notEqual(feeData.maxFeePerGas, null); assert.notEqual(feeData.maxPriorityFeePerGas, null); assert.notEqual(feeData.gasPrice, null); - }); + }).timeout(5_000);; it("block has gasLimit", async () => { const fullBlock = await provider.send("eth_getBlockByNumber", [ @@ -40,7 +40,7 @@ describe("ethers.js compatibility tests with state", () => { true, ]); assert.isTrue(fullBlock.hasOwnProperty("gasLimit")); - }); + }) it("block has baseFeePerGas", async () => { const fullBlock = await provider.send("eth_getBlockByNumber", [ @@ -48,5 +48,5 @@ describe("ethers.js compatibility tests with state", () => { true, ]); assert.isTrue(fullBlock.hasOwnProperty("baseFeePerGas")); - }); + }) }); diff --git a/e2e_test/run_all_tests.sh b/e2e_test/run_all_tests.sh index 9d0675abd1..952c18d6e3 100755 --- a/e2e_test/run_all_tests.sh +++ b/e2e_test/run_all_tests.sh @@ -31,6 +31,8 @@ cd "$SCRIPT_DIR" || exit 1 # To work around this, send a transaction before running tests cast send --json --private-key "$ACC_PRIVKEY" "$TOKEN_ADDR" 'transfer(address to, uint256 value) returns (bool)' 0x000000000000000000000000000000000000dEaD 100 > /dev/null || true +sleep 5 + failures=0 tests=0 echo "Globbing with \"$TEST_GLOB\""