hardhat
hardhat copied to clipboard
Support code coverage in v3
Expand the JS/TS integration testing with explicit support for code coverage.
This will require injecting slang into the testing pipeline to parse and modify the Solidity code under test to include coverage instrumentation.
An initial design doc, that should be refined is available here: https://www.notion.so/nomicfoundation/Code-Coverage-in-Hardhat-3-1cf578cdeaf580a4b640f394cb70da40
TODO
- [x] Update the build pipeline to run instrumentation
- [x] Update EDR instantiation to pass appropriate config + metadata
- [x] Collecting, computing and merging coverage from multiple EDR providers
- [x] lcov file generation
- [x] Integration of reporting into Node Test Runner
- [x] Integration of reporting into Mocha
- [ ] Integration of reporting into Solidity test
#6637 Pls check this implementation. See if its anything worthwhile. Thanks