From e8634b60c9dccb844f445d9980453f370c1443e9 Mon Sep 17 00:00:00 2001 From: Nicolas Martinelli Date: Fri, 5 Jan 2018 13:28:48 +0100 Subject: [PATCH] [FIX] purchase: almost equal Prevent failing test. opw-802764 --- addons/purchase/tests/test_stockvaluation.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/addons/purchase/tests/test_stockvaluation.py b/addons/purchase/tests/test_stockvaluation.py index 0d30ed9454c..0421bde3f71 100644 --- a/addons/purchase/tests/test_stockvaluation.py +++ b/addons/purchase/tests/test_stockvaluation.py @@ -171,7 +171,7 @@ class TestStockValuation(TransactionCase): # the unit price of the move is the unit price of the purchase order line converted in # the company's currency - self.assertEqual(move1.price_unit, price_unit_usd) + self.assertAlmostEqual(move1.price_unit, price_unit_usd) # change the rate of the currency self.env['res.currency.rate'].create({ @@ -187,7 +187,7 @@ class TestStockValuation(TransactionCase): self.assertLess(price_unit_usd_new_rate, price_unit_usd) # the unit price on the stock move is not directly updated - self.assertEquals(move1.price_unit, price_unit_usd) + self.assertAlmostEqual(move1.price_unit, price_unit_usd) # validate the receipt res_dict = picking1.button_validate()