chmarti1 / PYroMat

PYroMat thermodynamic properties in Python
http://pyromat.org
Other
71 stars 13 forks source link

Add tests for unit convertors, fix bugs identified in Issue #61 #63

Closed jranalli closed 1 year ago

jranalli commented 1 year ago

This branch does 3 things, which should close #61:

  1. Creates a new test code that handles unit convertors. This seems like a reasonable area to have tests running, because of the confidence we need for those functions.
  2. Fixes bugs identified in #61 about time conversion, as well as one not previously identified bug with the mass conversion to slugs.
  3. Fixes a bug I identified as I was writing the tests, where using the inplace parameter throws confusing errors if you haven't passed in a numpy type. This makes sense because the raw float, int, etc. aren't mutable anyway.

The changes to units.py are actually very small, so should be easy to look over.

jranalli commented 1 year ago
  1. Corrects documentation of the table in the docstrings for pm.units.Conversion.
chmarti1 commented 1 year ago

I'll pull this in along with the units fix for issue #64. I'll release them all together with v2.2.3.