blender/tests
Bastien Montagne 8535b9bd15 Fix T38722: Adding units in Imperial setting results in inconsistent values
Now always check for a default unit, and evaluate the whole expression in this "unit space".
Not an ideal solution, but should handle most cases nicely
(we can't address all possible corner cases anyway).

Note default unit is searched in current string first (bigger unit of current system wins),
then in previous string.

Note this also replaces ',' by '+' in default separation between units,
helps solving issues with parenthesis (e.g. (1'1")*2.5 would fail in existing code)!
This would break if someone uses py ops with lower precedence than '+' (like bitwise
operations, and comparison), but these are not expected usecase here anyway.

Reviewers: campbellbarton

Differential Revision: https://developer.blender.org/D340
2014-08-20 12:12:03 +02:00
..
gtests Fix incorrect comments in listbase, add unit test to verify change 2014-08-05 10:33:24 -04:00
python Fix T38722: Adding units in Imperial setting results in inconsistent values 2014-08-20 12:12:03 +02:00
check_deprecated.py
CMakeLists.txt GTest unit testing framework 2014-06-19 02:09:16 +10:00