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

Add more unit tests to increase coverage #355

Merged
merged 33 commits into from
Oct 29, 2024

Conversation

kenlig
Copy link
Contributor

@kenlig kenlig commented Sep 29, 2024

WIP

This PR adds some unit tests to increase coverage. Tests are mainly in attach and runtime sections.

Copy link

codecov bot commented Sep 29, 2024

Codecov Report

Attention: Patch coverage is 93.75000% with 2 lines in your changes missing coverage. Please review.

Project coverage is 52.80%. Comparing base (327ba8d) to head (98170b7).
Report is 1 commits behind head on master.

Files with missing lines Patch % Lines
...ach_impl/test/test_attach_private_data_parsing.cpp 75.00% 2 Missing ⚠️
Additional details and impacted files
@@             Coverage Diff             @@
##           master     #355       +/-   ##
===========================================
- Coverage   92.90%   52.80%   -40.11%     
===========================================
  Files          37       99       +62     
  Lines        1720     9426     +7706     
  Branches      103      956      +853     
===========================================
+ Hits         1598     4977     +3379     
- Misses        122     4449     +4327     
Flag Coverage Δ
attach tests (uprobe & syscall trace) 97.96% <100.00%> (+0.66%) ⬆️
coverage-example-fedora-false-bashreadline-false 13.28% <0.00%> (?)
coverage-example-fedora-false-bashreadline-true 13.28% <0.00%> (?)
coverage-example-fedora-false-funclatency-false 10.85% <0.00%> (?)
coverage-example-fedora-false-funclatency-true 10.85% <0.00%> (?)
coverage-example-fedora-false-malloc-true 12.15% <0.00%> (?)
coverage-example-fedora-false-minimal-false 9.81% <0.00%> (?)
coverage-example-fedora-false-minimal-true 9.81% <0.00%> (?)
coverage-example-fedora-false-mountsnoop-true 13.97% <0.00%> (?)
coverage-example-fedora-false-opensnoop-libbpf-tools-true 14.99% <0.00%> (?)
coverage-example-fedora-false-opensnoop-true 13.97% <0.00%> (?)
coverage-example-fedora-false-sigsnoop-true 22.86% <0.00%> (?)
coverage-example-fedora-false-sslsniff-false 14.76% <0.00%> (?)
coverage-example-fedora-false-sslsniff-true 14.76% <0.00%> (?)
coverage-example-fedora-false-statsnoop-true 14.99% <0.00%> (?)
coverage-example-fedora-false-syscount-false 9.55% <0.00%> (?)
coverage-example-fedora-false-syscount-true 11.15% <0.00%> (?)
coverage-example-fedora-false-tailcall_minimal-true 9.91% <0.00%> (?)
coverage-example-fedora-false-usdt_minimal-false 10.81% <0.00%> (?)
coverage-example-fedora-false-usdt_minimal-true 10.81% <0.00%> (?)
coverage-example-fedora-true-bashreadline-false 12.90% <0.00%> (?)
coverage-example-fedora-true-bashreadline-true 12.90% <0.00%> (?)
coverage-example-fedora-true-funclatency-false 10.54% <0.00%> (?)
coverage-example-fedora-true-funclatency-true 10.54% <0.00%> (?)
coverage-example-fedora-true-malloc-true 11.80% <0.00%> (?)
coverage-example-fedora-true-minimal-false 9.53% <0.00%> (?)
coverage-example-fedora-true-minimal-true 9.53% <0.00%> (?)
coverage-example-fedora-true-mountsnoop-true 13.57% <0.00%> (?)
coverage-example-fedora-true-opensnoop-libbpf-tools-true 14.56% <0.00%> (?)
coverage-example-fedora-true-opensnoop-true 13.57% <0.00%> (?)
coverage-example-fedora-true-sigsnoop-true 22.21% <0.00%> (?)
coverage-example-fedora-true-sslsniff-false 14.34% <0.00%> (?)
coverage-example-fedora-true-sslsniff-true 14.34% <0.00%> (?)
coverage-example-fedora-true-statsnoop-true 14.56% <0.00%> (?)
coverage-example-fedora-true-syscount-false 7.88% <0.00%> (?)
coverage-example-fedora-true-syscount-true 10.83% <0.00%> (?)
coverage-example-fedora-true-tailcall_minimal-true 9.63% <0.00%> (?)
coverage-example-fedora-true-usdt_minimal-false 10.50% <0.00%> (?)
coverage-example-fedora-true-usdt_minimal-true 10.50% <0.00%> (?)
coverage-example-ubuntu-false-bashreadline-false 28.61% <ø> (?)
coverage-example-ubuntu-false-bashreadline-true 28.61% <ø> (?)
coverage-example-ubuntu-false-funclatency-false 23.42% <ø> (?)
coverage-example-ubuntu-false-funclatency-true 23.42% <ø> (?)
coverage-example-ubuntu-false-malloc-true 26.24% <ø> (?)
coverage-example-ubuntu-false-minimal-false 21.19% <ø> (?)
coverage-example-ubuntu-false-minimal-true 21.19% <ø> (?)
coverage-example-ubuntu-false-mountsnoop-true 30.17% <ø> (?)
coverage-example-ubuntu-false-opensnoop-libbpf-tools-true 32.31% <ø> (?)
coverage-example-ubuntu-false-opensnoop-true 30.17% <ø> (?)
coverage-example-ubuntu-false-sigsnoop-true 40.04% <0.00%> (?)
coverage-example-ubuntu-false-sslsniff-false 31.81% <ø> (?)
coverage-example-ubuntu-false-sslsniff-true 31.81% <ø> (?)
coverage-example-ubuntu-false-statsnoop-true 32.31% <ø> (?)
coverage-example-ubuntu-false-syscount-false 17.35% <0.00%> (?)
coverage-example-ubuntu-false-syscount-true 24.06% <ø> (?)
coverage-example-ubuntu-false-tailcall_minimal-true 21.39% <ø> (?)
coverage-example-ubuntu-false-usdt_minimal-false 23.33% <ø> (?)
coverage-example-ubuntu-false-usdt_minimal-true 23.33% <ø> (?)
coverage-example-ubuntu-true-bashreadline-false 28.61% <ø> (?)
coverage-example-ubuntu-true-bashreadline-true 28.61% <ø> (?)
coverage-example-ubuntu-true-funclatency-false 23.42% <ø> (?)
coverage-example-ubuntu-true-funclatency-true 23.42% <ø> (?)
coverage-example-ubuntu-true-malloc-true 26.24% <ø> (?)
coverage-example-ubuntu-true-minimal-false 21.19% <ø> (?)
coverage-example-ubuntu-true-minimal-true 21.19% <ø> (?)
coverage-example-ubuntu-true-mountsnoop-true 30.17% <ø> (?)
coverage-example-ubuntu-true-opensnoop-libbpf-tools-true 32.31% <ø> (?)
coverage-example-ubuntu-true-opensnoop-true 30.17% <ø> (?)
coverage-example-ubuntu-true-sigsnoop-true 40.04% <0.00%> (?)
coverage-example-ubuntu-true-sslsniff-false 31.81% <ø> (?)
coverage-example-ubuntu-true-sslsniff-true 31.81% <ø> (?)
coverage-example-ubuntu-true-statsnoop-true 32.31% <ø> (?)
coverage-example-ubuntu-true-syscount-false 17.55% <ø> (?)
coverage-example-ubuntu-true-syscount-true 24.06% <ø> (?)
coverage-example-ubuntu-true-tailcall_minimal-true 21.39% <ø> (?)
coverage-example-ubuntu-true-usdt_minimal-false 23.33% <ø> (?)
coverage-example-ubuntu-true-usdt_minimal-true 23.33% <ø> (?)
runtime tests 47.17% <0.00%> (-43.99%) ⬇️

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

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

@pull-request-size pull-request-size bot added size/M and removed size/S labels Oct 19, 2024
@pull-request-size pull-request-size bot added size/L and removed size/M labels Oct 27, 2024
@Officeyutong Officeyutong marked this pull request as ready for review October 28, 2024 06:23
@yunwei37 yunwei37 merged commit 808ce59 into eunomia-bpf:master Oct 29, 2024
93 of 94 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants