fix: test case correction

(cherry picked from commit 2f7e6230a6)
This commit is contained in:
Khushi Rawat
2024-12-23 23:37:51 +05:30
committed by Mergify
parent 516a325a31
commit ddfead2cde
2 changed files with 2 additions and 2 deletions

View File

@@ -889,7 +889,7 @@ class TestDepreciationMethods(AssetSetup):
["2030-12-31", 28630.14, 28630.14],
["2031-12-31", 35684.93, 64315.07],
["2032-12-31", 17842.46, 82157.53],
["2033-06-06", 5342.46, 87499.99],
["2033-06-06", 5342.47, 87500.00],
]
schedules = [

View File

@@ -344,7 +344,7 @@ class AssetDepreciationSchedule(Document):
date_of_disposal,
original_schedule_date=schedule_date,
)
depreciation_amount = flt(depreciation_amount, asset_doc.precision("gross_purchase_amount"))
if depreciation_amount > 0:
self.add_depr_schedule_row(date_of_disposal, depreciation_amount, n)