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

feat(bytes): Added size #34

Merged
merged 1 commit into from
Dec 7, 2023
Merged

feat(bytes): Added size #34

merged 1 commit into from
Dec 7, 2023

Conversation

flc1125
Copy link
Member

@flc1125 flc1125 commented Dec 7, 2023

No description provided.

Copy link

codecov bot commented Dec 7, 2023

Codecov Report

All modified and coverable lines are covered by tests ✅

Comparison is base (ebe94ee) 75.00% compared to head (19eed16) 77.03%.

Additional details and impacted files
@@            Coverage Diff             @@
##           master      #34      +/-   ##
==========================================
+ Coverage   75.00%   77.03%   +2.03%     
==========================================
  Files          22       23       +1     
  Lines         608      662      +54     
==========================================
+ Hits          456      510      +54     
  Misses        135      135              
  Partials       17       17              

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

Copy link

what-the-diff bot commented Dec 7, 2023

PR Summary

  • Introduction of the 'Bytes' Type Functionality
    A new file has been added named bytes/size.go, which presents a noteworthy feature, 'Bytes'. This newly implemented 'Bytes' type aids in easily transitioning between diverse units of bytes (KB, MB, GB, and so on). A notable highlight of 'Bytes' is its ability to format values into an easy-to-understand format, along with providing the unit of the formatted value through a Unit method.

  • Testing of the 'Bytes' type
    A new accompanying test file called bytes/size_test.go has also been launched in this pull request. The main purpose of these tests is to ensure the flawless working of Bytes type, particularly focusing on Humanize and HumanizeValue methods. Through these tests, we aim to validate the accurate formatting process acquired by different unit values of Bytes.

@flc1125 flc1125 merged commit aca70d2 into master Dec 7, 2023
6 checks passed
@flc1125 flc1125 deleted the feat-bytes branch December 8, 2023 14:28
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.

1 participant