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

♻️Allow custom units to set UnitInfo.QuantityName #1420

Merged
merged 1 commit into from
Aug 31, 2024

Conversation

angularsen
Copy link
Owner

@angularsen angularsen commented Aug 31, 2024

Fixes #1418

  • Make UnitInfo ctor public, to accept quantity name for custom units
  • Add null checks to ctors, and require quantity name in ctor that takes one
  • Mark ctor without quantity name obsolete

- Make ctor, which takes quantity name, public
- Add null checks to ctors, and require quantity name in ctor that takes one
- Mark ctor without quantity name obsolete
@angularsen angularsen enabled auto-merge (squash) August 31, 2024 20:10
angularsen added a commit that referenced this pull request Aug 31, 2024
Related #1418
Port of #1420 

- Make `UnitInfo` ctor public, to accept quantity name for custom units
- Add null checks to ctors, and require quantity name in ctor that takes
one
- Mark ctor without quantity name obsolete
Copy link

codecov bot commented Aug 31, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 84%. Comparing base (0eff43e) to head (5c999e8).
Report is 1 commits behind head on master.

Additional details and impacted files
@@          Coverage Diff           @@
##           master   #1420   +/-   ##
======================================
  Coverage      84%     84%           
======================================
  Files         345     345           
  Lines       33142   33146    +4     
======================================
+ Hits        27935   27939    +4     
  Misses       5207    5207           

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

@angularsen angularsen merged commit 20062c7 into master Aug 31, 2024
3 checks passed
@angularsen angularsen deleted the agl/fix-unitinfo-ctor branch August 31, 2024 20:20
@angularsen
Copy link
Owner Author

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.

Can not set QuantityName for Custom Units
1 participant