You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When using the modifierWhitelist option in the sol coverage config. It correctly excludes the modifiers specified however it also causes random pasts of coverage to go missing.
The text was updated successfully, but these errors were encountered:
Do you have a link to a public repo where I could see this happening? Or some way of reproducing this problem?
It's possible that running hardhat clean would resolve this...solidity-coverage sometimes behaves weirdly if you change the .solcover configuration between coverage runs.
Do you have a link to a public repo where I could see this happening? Or some way of reproducing this problem?
It's possible that running hardhat clean would resolve this...solidity-coverage sometimes behaves weirdly if you change the .solcover configuration between coverage runs.
Hey thanks for your response! I don't think hardhat clean fixes the issue because I've run this in the past as part of a script that firstly clears the cache then runs the coverage report. I believe the issue occurs when there are many contracts and tests running. On the projects I've encountered this issue on there have been 1k+ unit tests. I've attempted to reproduce this doing a simple set of tests and I was unable to replicate the issue.
@BlockAlchemist Ok, thanks for reporting. Will keep a lookout for this.
Another possibility based on your description is that there's a missing await somewhere in the test suite or some non-deterministic time-based logic. Enabling or disabling the modifier coverage will change how long it takes the client to run the code and this might result in variance.
When using the modifierWhitelist option in the sol coverage config. It correctly excludes the modifiers specified however it also causes random pasts of coverage to go missing.
The text was updated successfully, but these errors were encountered: