accounting: always compare rounded values when indexing balance transactions
To prevent rounding errors, we always compare rounded values to the precision of the accounting currency. There was a place here where we were using -= without rounding, which caused to detect a difference between new and current stock and insert a line for 0 in an existing instance for which some accounting lines were created with too precise values - but not in a way that was detected by the assertions in AccountingPeriod_createBalanceTransaction. Rounding here as well solved the problem with that data.
Status | Job ID | Name | Coverage | ||||||
---|---|---|---|---|---|---|---|---|---|
External | |||||||||
passed |
#473503
external
|
ERP5.CodingStyleTest-Master |
00:50:08
|
||||||
passed |
#473514
external
|
ERP5.PerformanceTest-Master |
00:26:59
|
||||||
failed |
#473498
external
|
ERP5.UnitTest-Master |
01:33:08
|
||||||
failed |
#473497
external
|
ERP5.UnitTest-Master.Medusa |
01:31:02
|
||||||
passed |
#473507
external
|
SlapOS.Eggs.UnitTest-Master.Python2 |
00:13:42
|
||||||
passed |
#473522
external
|
SlapOS.Eggs.UnitTest-Master.Python3 |
00:13:02
|
||||||