pacti-org / pacti

A package for compositional system analysis and design
https://www.pacti.org
BSD 3-Clause "New" or "Revised" License
19 stars 5 forks source link

[Feature request] Setup rich monitors for Pacti #294

Closed iincer closed 1 year ago

iincer commented 1 year ago

We need to increase testing on Pacti. To do this, it would be helpful to have an easy way to browse coverage data. Currently, we can run make test and make coverage. This will generate an html report locally. This report has line-by-line coverage.

Can we export this report to a web service (maybe GitHub?) in order to quickly know what has to be improved? It would be great to have access to all sorts of "vitals" of the project: tests, types, coverage. Does GitHub Actions support nice html rendering? If not, we could use a third party app connected to GitHub, such as Travis CI.

iincer commented 1 year ago

Codecov and Codacity seem to be good options that are free for open source projects.

ayush9pandey commented 1 year ago

I've used Codecov before and some of it I started to setup with the badges branch. I think Codecov works only for open-source repos though..

iincer commented 1 year ago

Progress towards this can be found in 63a35b417f809369480265f1e18f19f456028937

iincer commented 1 year ago

Hi @ayush9pandey, is the codecov badge fully setup? It doesn't give information now. Do we need to run something for it to update?

ayush9pandey commented 1 year ago

I looked into this. The coverage report is not properly read by Codecov. image

This is what it's seeing, which is unexpected.

ayush9pandey commented 1 year ago

The reason why we are not seeing coverage on the main branch is because no CIs have been run on the main branch (our CIs are setup to be run manually). The PR #314 addresses this by modifying the existing CIs to include coverage tasks. Hopefully, when we run these manually the coverage gets pushed from main to Codecov for tracking. It might fail because make check and others will fail...but coverage is placed before it..so it might work.

ayush9pandey commented 1 year ago

It worked!

ayush9pandey commented 1 year ago

The badge is also correctly displaying the coverage percentage. All that's left to do now is to increase the coverage to atleast 80% 🥇 that will change the red background in the coverage badge to green!