[FIX] point_of_sale: use correct rate date in test

Since changes made in currency rate default value made in this PR
https://github.com/odoo/odoo/pull/76513 the date is stored based on user
timezone, and so doesn't work if the test runs around midnight with the
belgian timezone on the servers.

closes odoo/odoo#78480

X-original-commit: 0dc9a2d47833f2a13dce9891e7710815b4d27584
Signed-off-by: pimodoo <pimodoo@users.noreply.github.com>
This commit is contained in:
Pierre Masereel
2021-10-17 10:37:41 +00:00
parent fae2bd0c28
commit cf875e4797
+2
View File
@@ -1,5 +1,6 @@
# -*- coding: utf-8 -*-
from random import randint
from datetime import datetime
from odoo import fields, tools
from odoo.addons.stock_account.tests.test_anglo_saxon_valuation_reconciliation_common import ValuationReconciliationTestCommon
@@ -276,6 +277,7 @@ class TestPoSCommon(ValuationReconciliationTestCommon):
cls.env['res.currency.rate'].create({
'rate': 0.5,
'currency_id': cls.other_currency.id,
'name': datetime.today().date(),
})
other_cash_journal = cls.env['account.journal'].create({
'name': 'Cash Other',