-
Notifications
You must be signed in to change notification settings - Fork 0
Basic code coverage feedback #10
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
Conversation
a9cd68e to
be6d5ac
Compare
TimSheard
left a comment
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.
This PR sets up the creation of code coverage measurements.
Not being an expert, I cannot comment on whether this will have any adverse consequences, unless one figures increased build times?
|
@TimSheard we aren't changing any requirements, so we aren't forcing coverage metrics on anyone (which is probably wise). What we are trying to achieve here is mostly getting a grip on "how good are our tests at exercising the code" and the main take-away is that we are probably missing some stuff (big or small?) and we should look into it. The next thing to do would be to compare coverage on master and the PR branch in the comment, that would give us a better idea of how a PR may or may not change coverage. |
Coverage report
On masterCoverage report
|
ce918ed to
f931e79
Compare
Soupstraw
left a comment
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.
LGTM
neilmayhew
left a comment
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.
I love having the coverage in a PR comment!
4c30356 to
af3b6c6
Compare
|
FYI, in ledger we prefer to have all merges in |
|
@neilmayhew would you mind doing another review here? |
Co-authored-by: Neil Mayhew <[email protected]>
Co-authored-by: Neil Mayhew <[email protected]>
|
@neilmayhew if you'd like to have a look now and hopefully press the green button that'd be great. I think I've addressed all your concerns. I've also taken the libery to remove the There is an open issue for proper haddoc CI that I will get to eventually. |
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.
Looks great now!
Hopefully this can be used as a reference for adding coverage to other repos' CI
|
Unfortunately, there are 5 checks that are never going to complete because GitHub has become confused by the change of job name. I've enabled auto-merge, but I think it's going to need someone with admin rights (@lehins) to force the merge. |
I can open a new PR instead. |
1 similar comment
I can open a new PR instead. |
lehins
left a comment
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.
Sorry @MaximilianAlgehed
But there are much better ways to deal with coverage on Haskell projects.
This is an overly complex solution with an outcome that is far inferior to other solutions.
Here is an example of coverage report for a Haskell project named cuddle that we use in ledger as well: https://coveralls.io/github/input-output-hk/cuddle
If you'd like to set it up in the same way, I'd be in favor.
Or I can ask one of our team mates to do this instead if you'd prefer. Here is how it is configured: https://github.com/input-output-hk/cuddle/blob/7fe3abb67a4cf28368d45b40576572ca667dd66a/.github/workflows/ci.yml#L129-L141
|
@lehins I'd be super grateful if someone could set up something like this! Maybe better to ask someone whose done it before and has the correct privileges. It will help in doing exactly what I was hoping for here. I'll admit that this PR spun out of me just using hpc locally to get an idea of the state of things - it should have crossed my mind that IOG has an existing solution for this. I was planning to take the output here and make it much prettier, but better to use an existing solution for that. Not much work lost and a bunch saved! |
I was playing around with HPC to get some idea of the state of the tests and I thought it might be worth a shot to get the feedback in PRs mostly as an exercise. More importantly, we should do something about some of the low numbers here.