[FIX] calendar: use a contextual timestamp in test

When the test starts after 00:00:00 UTC, the test fails.

closes odoo/odoo#60891

X-original-commit: c62acb48ac3ae11180a6817321664fb01833d3bd
Signed-off-by: Yannick Tivisse (yti) <yti@odoo.com>
Signed-off-by: Christophe Monniez (moc) <moc@odoo.com>
This commit is contained in:
Christophe Monniez
2020-10-28 11:38:42 +00:00
parent 59ecc564e0
commit a431ee3f52
+1 -1
View File
@@ -274,7 +274,7 @@ class TestCalendar(SavepointCaseWithUserDemo):
self.env['res.partner'].create({'name': 'testuser1', 'email': u'alice@example.com'}),
]
partner_ids = [(6, False, [p.id for p in partners]),]
now = fields.Datetime.now()
now = fields.Datetime.context_timestamp(partners[0], fields.Datetime.now())
m = self.CalendarEvent.create({
'name': "mailTest1",
'allday': False,