NomicFoundation / hardhat

Hardhat is a development environment to compile, deploy, test, and debug your Ethereum software.
https://hardhat.org
Other
7.12k stars 1.36k forks source link

Make hardhat-chai-matchers compatible with hardhat-viem / library-agnostic #4874

Open schaable opened 6 months ago

schaable commented 6 months ago

The hardhat-chai-matchers plugin is currently only compatible with hardhat-ethers. This issue aims to see if there's interest in making it work with hardhat-viem and other Ethereum libraries. Please upvote or comment if you think this would be an useful feature.

dennis-gonzales commented 5 months ago

viem is great imo, hopefully we can support this when able.

andreujuanc commented 3 months ago

Would love to have this! much more cleaner with the matchers!

mwawrusch commented 3 months ago

To add to that, hardhat-chain-matchers now uses the chaiAsPromised library which is not maintained anymore and is incompatible with chai 5. So it would make sense to upgrade / replace that as well while getting viem going.

petdomaa100 commented 3 months ago

+1

johnpm-12 commented 3 months ago

I put up a PR to add a viem specific package for chai matchers: #5252

In case anyone finds it useful, in the meantime, I deployed it here: https://www.npmjs.com/package/hardhat-chai-matchers-viem