please god, please ethers support
Hi all,
Really happy to see some Truffle suite alternatives.
But, I have one comment: ethers.js, ethers.js, ethers.js, ethers.js
Please support ethers.js contracts / preferences.
Best, Ethereum Friend.
Thank you for the feedback @SilentCicero. We will definitely keep this in mind for planning.
I'd also love to see ethers.js support.
This will spill over into @openzeppelin/test-helpers, since expectEvent doesn't support ethers-style receipts, though I assume you're already aware of this.
Another thing to consider when supporting this is to make sure it supports ganache forks properly. I tried using ethers in testing manually, but as soon as contract development progressed to the stage of needing to fork the mainnet, transactions started failing.
For example, these lines worked until I started forking the mainnet:
const TestToken = contract.fromArtifact('TestToken');
const tokenFactory = new ethers.ContractFactory(TestToken.abi, TestToken.bytecode, wallet);
usdc = await tokenFactory.deploy('USD Coin', 'USDC');
await usdc.deployTransaction.wait();
When forking, the above fails with Error: Missing required chain parameter: networkId
You can confirm the issue is related to ethers.js usage because if you refactor to the below, the transaction succeeds again:
const TestToken = contract.fromArtifact('TestToken');
const usdc = await TestToken.new("USD Coin", "USDC");