-
Notifications
You must be signed in to change notification settings - Fork 45
Add coverage #429
Add coverage #429
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice coverage already!
Maybe it would be cool to run coverage on CI and upload the results to https://coveralls.io/ so that we get the nice little Badge on our repo readme (here is the line that did it in GPv1)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sweet sauce! Now we just need to upload the coverage to coveralls or something and setup the badge.
I'm also more than happy to merge this PR as-is even with the pragma abicode v2
issue in the solidity coverage plugin. We will just have to skip v0.7.14 and close the Dependabot PR.
Co-authored-by: Nicholas Rodrigues Lordello <nlordell@gmail.com>
I think it would be nice to have this check but maybe make it non-blocking? On the other hand as admins we can still merge requests that have a blocking check not pass. |
I consider this PR ready: the only changes that I still intend to include are these. I'm not implementing them without confirmation since doing so would give (a malicious) Coveralls unfettered access to this repo (the command receives a GitHub token that allows it to make almost arbitrary git changes). The alternative would be implementing this manually with Coveralls's API or without Coveralls. In GPv1 a malicious Coveralls would have access to secret CI env variables but was not able to change the repo itself. Wdyt @fleupold, @nlordell? |
Do you know what permissions the Coveralls app needs? To me it looks like it just wants to authenticate that it is the repo, so maybe you can create a "personal access token" for Coveralls?
|
To my understanding, it needs some write access because it adds a new check on our repo. Also, you cannot create a custom personal access token for a single project, it can only inherit its permissions from an actual account. The only way down this route I see is creating a dedicated GitHub account, add it to the list of people allowed to make changes to the repo and then use it to create a personal access token. |
Boo! |
I guess its similar to how we give apps like Mergify repository access, so I'm OK with it. |
I think the way the repo is set up only the Mergify rule and GitHub action prevent merging: Additionally, the mergify configuration only checks the GitHub action check: Lines 3 to 7 in 7011673
I think its better for coverage decreases to show a big red X so we don't miss it, while, given the current configuration, should not prevent merging. |
PR is ready without changes from the draft. Only exception is that I updated |
This is why I'm merging manually, all other checks are otherwise successful. |
Adds coverage reporting to this project.
Note that coverage testing skips all end to end tests. The motivation is twofold:
hardhat-deploy
bypasses the Hardhat network flagallowUnlimitedContractSize
.Test Plan
Instructions in readme.
Expected result: