Skip to content
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

Code coverage issue. #755

Closed
badrik-pedalsup opened this issue Sep 26, 2022 · 2 comments
Closed

Code coverage issue. #755

badrik-pedalsup opened this issue Sep 26, 2022 · 2 comments

Comments

@badrik-pedalsup
Copy link

My all test cases are passing but still, code coverage is 0.
I have written test cases using hardhat.

@SvineruS
Copy link

SvineruS commented Jan 21, 2023

Had the same problem.

I had several versions of the compiler (0.4.24 and 0.8.17) and contracts with those versions.
I left only version 0.8.17, the coverage started working correctly.
UPD: also removed evmVersion: "byzantium"

But it's strange, I have another project with the same versions of solidity, but used a different hardhat environment (fork of solidity-coverage from august 2021; hardhat-deploy; without hardhat-toolbox) and everything works fine

@cgewecke
Copy link
Member

The primary reason people are seeing 0% coverage is because viaIR is set to true. Tracking that in #715

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants