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

[CI] Add coveragepy and remove ignore: test #1668

Merged
merged 11 commits into from
Aug 14, 2024
Merged

[CI] Add coveragepy and remove ignore: test #1668

merged 11 commits into from
Aug 14, 2024

Conversation

christophfroehlich
Copy link
Contributor

@christophfroehlich christophfroehlich commented Aug 13, 2024

Recently we worked a lot on the spawner scripts, maybe we should add coverage data also for them.

The only problem is that we don't test them with pytest but with system calls from C++ files. This needs to manually invoke coverage.py with the python modules by the std::system calls instead of using ros2 run

Most of the necessary changes are ros-controls/ros2_control_ci#115

Recently, the codecov setting to ignore the test folders did not work and they got included (which increased our coverage numbers). I removed the ignore line, and intentional add the tests to the coverage where there are good arguments for it anyways.

Copy link

codecov bot commented Aug 13, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 86.73%. Comparing base (07fb4f3) to head (7fa5b1f).

Additional details and impacted files
@@            Coverage Diff             @@
##           master    #1668      +/-   ##
==========================================
+ Coverage   84.59%   86.73%   +2.13%     
==========================================
  Files         115      115              
  Lines       10537    10539       +2     
  Branches      972      972              
==========================================
+ Hits         8914     9141     +227     
+ Misses       1295     1052     -243     
- Partials      328      346      +18     
Flag Coverage Δ
unittests 86.73% <100.00%> (+2.13%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

Files Coverage Δ
controller_manager/test/test_spawner_unspawner.cpp 99.00% <100.00%> (+0.01%) ⬆️

... and 5 files with indirect coverage changes

@christophfroehlich christophfroehlich changed the title [CI] Add coveragepy [CI] Add coveragepy and remove ignore: test Aug 14, 2024
@christophfroehlich christophfroehlich marked this pull request as ready for review August 14, 2024 09:51
bmagyar
bmagyar previously approved these changes Aug 14, 2024
Copy link
Contributor

mergify bot commented Aug 14, 2024

This pull request is in conflict. Could you fix it @christophfroehlich?

Copy link
Member

@bmagyar bmagyar left a comment

Choose a reason for hiding this comment

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

alles gut

@bmagyar bmagyar merged commit 3cf167d into master Aug 14, 2024
19 checks passed
@bmagyar bmagyar deleted the coveragepy branch August 14, 2024 12:51
Copy link
Member

@saikishor saikishor left a comment

Choose a reason for hiding this comment

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

LGTM

@fmauch fmauch mentioned this pull request Aug 14, 2024
destogl pushed a commit that referenced this pull request Aug 15, 2024
* Add a pytest launch file to test ros2_control_node (#1636)
* [CI] Add coveragepy and remove ignore: test (#1668)
mergify bot pushed a commit that referenced this pull request Aug 19, 2024
* Add a pytest launch file to test ros2_control_node (#1636)
* [CI] Add coveragepy and remove ignore: test (#1668)

(cherry picked from commit 8b32c33)
christophfroehlich added a commit that referenced this pull request Aug 19, 2024
* Add a pytest launch file to test ros2_control_node (#1636)
* [CI] Add coveragepy and remove ignore: test (#1668)

(cherry picked from commit 8b32c33)

Co-authored-by: Christoph Fröhlich <christophfroehlich@users.noreply.github.com>
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.

3 participants