-
Notifications
You must be signed in to change notification settings - Fork 264
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feature request: hybrid Foundry/Hardhat coverage #734
Comments
I don't think this is likely to happen (or desirable). Maybe hybrid repo users could just merge saved reports from different test runs using a tool like istanbul-combine-updated. You can select what kind of report to produce in solidity-coverage using the If you're using Codecov as a CI service, multiple reports uploaded at once will be auto-merged on their side. Does this approach seem reasonable for your use case? |
Thanks for the detailed answer @cgewecke - we're looking into implementing a solution using your answer. If you don't mind, I'll keep this open in the meantime just in case we run into trouble. |
https://github.com/hyperlane-xyz/hyperlane-monorepo/blob/main/solidity/coverage.sh we merge the two reports here |
I spent ages fiddling with this but hands down codecov is the best solution by far |
solidity-coverage
is currently a framework agnostic project. While Foundry is working on its own coverage tool, I think that there is value in extendingsolidity-coverage
's support to Foundry too. Once specific use case follows.Certain things are easier to test from JS/TS as an EOA. Some are easier to test as a smart contract (on-chain). Hardhat provides the former, Foundry provides the latter (and easy access from within tests to fuzz and invariant tests). Some repos have decided on a hybrid environment, bringing in features from both. Seaport is a prominent example.
Getting coverage results that include the coverage of both the JS/TS and Solidity tests would be where
solidity-coverage
could shine. Once the tool would be able to monitor coverage from Foundry, it would seem to me that it wouldn't be too hard for it to monitor overall coverage in a hybrid repo.If there's anything I can do to add context and/or information, please let me know.
Am I looking at this right?
The text was updated successfully, but these errors were encountered: