Skip to content

Conversation

loiseaujc
Copy link
Contributor

@loiseaujc loiseaujc commented Oct 7, 2025

Following the discussion in #937, this PR add code coverage to stdlib using codecov.

Key facts

  • Extends the fpm-deployment.yml Action with code coverage.
  • Uses fpm to run the test with the added -coverage flag added for compilation with gfortran.
  • Use the release profile with xdp and qp turned on.
  • Automatically upload the coverage report to codecov
  • Requires a CODECOV_TOKEN to be set up in the settings of the repo. This should be done by the one of the org owners I believe.

Ping: @perazz, @jalvesz, @jvdp1

PS : This is a re-opening of #1024 which was closed when I randomly decided to delete my fork.

Copy link

codecov bot commented Oct 7, 2025

Codecov Report

✅ All modified and coverable lines are covered by tests.
⚠️ Please upload report for BASE (master@eb46153). Learn more about missing BASE report.

Additional details and impacted files
@@            Coverage Diff            @@
##             master    #1039   +/-   ##
=========================================
  Coverage          ?   25.02%           
=========================================
  Files             ?      566           
  Lines             ?   233862           
  Branches          ?    41247           
=========================================
  Hits              ?    58534           
  Misses            ?   175328           
  Partials          ?        0           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Copy link
Member

@perazz perazz left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM @loiseaujc, however, I have no experience in codecoverage CI setups.

Copy link
Member

@jvdp1 jvdp1 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM! thank you @loiseaujc

@jalvesz
Copy link
Contributor

jalvesz commented Oct 8, 2025

Requires a CODECOV_TOKEN to be set up in the settings of the repo. This should be done by the one of the org owners I believe.

I'll poke @milancurcic and/or @certik, maybe they could help with this?

@milancurcic
Copy link
Member

Thanks, @loiseaujc. I set the CODECOV_TOKEN as an Actions secret on this repo.

version: ${{ matrix.toolchain.version }}

- name: Setup Fortran Package Manager
uses: fortran-lang/setup-fpm@v5
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

try with setup-fpm@v7 it should fix the path issue with the installer name.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I saw that setup-fpm is called twice in the yml file. It still fails because the second one still points to v5. I think this could be done just once by including the coverage steps after the deployment.

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

Successfully merging this pull request may close these issues.

5 participants