mirror of
https://github.com/bringout/oca-ocb-technical.git
synced 2026-04-23 10:52:03 +02:00
19.0 vanilla
This commit is contained in:
parent
5faf7397c5
commit
2696f14ed7
721 changed files with 220375 additions and 91221 deletions
|
|
@ -1,4 +1,3 @@
|
|||
# -*- coding: utf-8 -*-
|
||||
# Part of Odoo. See LICENSE file for full copyright and licensing details.
|
||||
|
||||
from datetime import datetime, time
|
||||
|
|
@ -6,7 +5,6 @@ from dateutil.relativedelta import relativedelta
|
|||
|
||||
import pytz
|
||||
|
||||
from odoo import Command
|
||||
from odoo import tests
|
||||
from odoo.addons.mail.tests.common import MailCommon
|
||||
|
||||
|
|
@ -44,14 +42,12 @@ class TestMailActivityMixin(MailCommon):
|
|||
})
|
||||
|
||||
def schedule_meeting_activity(record, date_deadline, calendar_event=False):
|
||||
meeting = record.activity_schedule('calendar.calendar_activity_test_default', date_deadline=date_deadline)
|
||||
meeting = record.activity_schedule('calendar.calendar_activity_test_default', date_deadline=date_deadline, user_id=self.env.uid)
|
||||
meeting.calendar_event_id = calendar_event
|
||||
return meeting
|
||||
|
||||
group_partner_manager = self.env['ir.model.data']._xmlid_to_res_id('base.group_partner_manager')
|
||||
self.user_employee.write({
|
||||
'tz': self.user_admin.tz,
|
||||
'groups_id': [Command.link(group_partner_manager)]
|
||||
})
|
||||
with self.with_user('employee'):
|
||||
test_record = self.env['res.partner'].browse(self.test_record.id)
|
||||
|
|
@ -78,5 +74,5 @@ class TestMailActivityMixin(MailCommon):
|
|||
|
||||
act1._action_done(feedback="Mark activity as done with text")
|
||||
|
||||
self.assertFalse(act1.exists(), "activity marked as done should be deleted")
|
||||
self.assertFalse(act1.active, "activity marked as done should be archived")
|
||||
self.assertTrue(ev1.exists(), "event of done activity must not be deleted")
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue