Update tests for current EIP-2930 support across backends (#1364).
This commit is contained in:
parent
25c3024a89
commit
1cb3199e5c
@ -247,6 +247,7 @@ const blockchainData: { [ network: string ]: TestCases } = {
|
||||
},
|
||||
],
|
||||
transactions: [
|
||||
// Berlin tests
|
||||
{
|
||||
hash: "0x48bff7b0e603200118a672f7c622ab7d555a28f98938edb8318803eed7ea7395",
|
||||
type: 1,
|
||||
@ -692,9 +693,8 @@ Object.keys(blockchainData).forEach((network) => {
|
||||
|
||||
return tx;
|
||||
}, test, (provider: string, network: string, test: TestDescription) => {
|
||||
// Temporary
|
||||
if (network === "ropsten" && provider === "PocketProvider") {
|
||||
console.log(`Skipping ${ provider }; incomplete Berlin support`);
|
||||
// Temporary; Pocket is having issues with old transactions on some testnets
|
||||
if ((network === "ropsten" || network === "goerli") && provider === "PocketProvider") {
|
||||
return true;
|
||||
}
|
||||
|
||||
@ -716,7 +716,14 @@ Object.keys(blockchainData).forEach((network) => {
|
||||
delete receipt.confirmations;
|
||||
|
||||
return receipt;
|
||||
}, test);
|
||||
}, test, (provider: string, network: string, test: TestDescription) => {
|
||||
// Temporary; Pocket is having issues with old transactions on some testnets
|
||||
if ((network === "ropsten" || network === "goerli") && provider === "PocketProvider") {
|
||||
return true;
|
||||
}
|
||||
|
||||
return false;
|
||||
});
|
||||
});
|
||||
});
|
||||
|
||||
@ -737,9 +744,17 @@ Object.keys(blockchainData).forEach((network) => {
|
||||
});
|
||||
}
|
||||
|
||||
/*
|
||||
@TODO: Use this for testing pre-EIP-155 transactions on specific networks
|
||||
addErrorTest(ethers.utils.Logger.errors.NONCE_EXPIRED, async (provider: ethers.providers.Provider) => {
|
||||
return provider.sendTransaction("0xf86480850218711a0082520894000000000000000000000000000000000000000002801ba038aaddcaaae7d3fa066dfd6f196c8348e1bb210f2c121d36cb2c24ef20cea1fba008ae378075d3cd75aae99ab75a70da82161dffb2c8263dabc5d8adecfa9447fa");
|
||||
});
|
||||
*/
|
||||
|
||||
// Wallet(id("foobar1234"))
|
||||
addErrorTest(ethers.utils.Logger.errors.NONCE_EXPIRED, async (provider: ethers.providers.Provider) => {
|
||||
return provider.sendTransaction("0xf86480850218711a00825208940000000000000000000000000000000000000000038029a04320fd28c8e6c95da9229d960d14ffa3de81f83abe3ad9c189642c83d7d951f3a009aac89e04a8bafdcf618e21fed5e7b1144ca1083a301fd5fde28b0419eb63ce");
|
||||
});
|
||||
|
||||
addErrorTest(ethers.utils.Logger.errors.INSUFFICIENT_FUNDS, async (provider: ethers.providers.Provider) => {
|
||||
|
||||
@ -747,6 +762,7 @@ Object.keys(blockchainData).forEach((network) => {
|
||||
to: "0x8ba1f109551bD432803012645Ac136ddd64DBA72",
|
||||
gasPrice: 9000000000,
|
||||
gasLimit: 21000,
|
||||
chainId: 3,
|
||||
value: 1
|
||||
};
|
||||
|
||||
@ -809,7 +825,7 @@ testFunctions.push({
|
||||
networks: [ "ropsten" ], // Only test on Ropsten
|
||||
checkSkip: (provider: string, network: string, test: TestDescription) => {
|
||||
// Temporary
|
||||
return (provider === "PocketProvider" || provider === "EtherscanProvider");
|
||||
return false;
|
||||
},
|
||||
execute: async (provider: ethers.providers.Provider) => {
|
||||
const wallet = fundWallet.connect(provider);
|
||||
|
Loading…
Reference in New Issue
Block a user