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

storage: add some unit test cases #1469

Merged
merged 1 commit into from
Nov 7, 2023
Merged

Conversation

hijackthe2
Copy link
Contributor

Some unit test cases are added for device.rs, meta/batch.rs, meta/chunk_info_v2.rs, meta/mod.rs, and meta/toc.rs in storage/src to increase code coverage.

Relevant Issue (if applicable)

If there are Issues related to this PullRequest, please list it.

Details

Please describe the details of PullRequest.

Types of changes

What types of changes does your PullRequest introduce? Put an x in all the boxes that apply:

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)
  • Documentation Update (if none of the other choices apply)

Checklist

Go over all the following points, and put an x in all the boxes that apply.

  • I have updated the documentation accordingly.
  • I have added tests to cover my changes.

@hijackthe2 hijackthe2 requested a review from a team as a code owner November 3, 2023 09:31
@hijackthe2 hijackthe2 requested review from jiangliu, gaius-qi and adamqqqplay and removed request for a team November 3, 2023 09:31
Copy link

codecov bot commented Nov 3, 2023

Codecov Report

Merging #1469 (d4f688f) into master (8b81a99) will increase coverage by 1.05%.
The diff coverage is 99.02%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #1469      +/-   ##
==========================================
+ Coverage   53.80%   54.85%   +1.05%     
==========================================
  Files         123      123              
  Lines       40172    40477     +305     
  Branches    40172    40477     +305     
==========================================
+ Hits        21613    22204     +591     
+ Misses      17333    17034     -299     
- Partials     1226     1239      +13     
Files Coverage Δ
builder/src/stargz.rs 74.67% <100.00%> (ø)
storage/src/device.rs 67.89% <100.00%> (+0.93%) ⬆️
storage/src/meta/batch.rs 97.70% <100.00%> (+97.70%) ⬆️
storage/src/meta/chunk_info_v2.rs 97.68% <100.00%> (+26.63%) ⬆️
storage/src/meta/mod.rs 67.88% <100.00%> (+5.58%) ⬆️
storage/src/meta/toc.rs 70.86% <96.73%> (+14.85%) ⬆️

... and 3 files with indirect coverage changes

Some unit test cases are added for device.rs, meta/batch.rs, meta/chunk_info_v2.rs, meta/mod.rs, and meta/toc.rs in storage/src to increase code coverage.

Signed-off-by: hijackthe2 <[email protected]>
@hijackthe2 hijackthe2 force-pushed the unit-test branch 2 times, most recently from d4f688f to 0d51c7e Compare November 6, 2023 02:57
@imeoer imeoer merged commit 89882a4 into dragonflyoss:master Nov 7, 2023
44 of 45 checks passed
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.

2 participants