odoo/addons/crm_caldav/test/test_crm_caldav.yml

38 lines
1.3 KiB
YAML

- |
Now Create test cases for Sharing meeting with other calendar clients like sunbird.
- |
I start by creating a new Meeting.
-
!record {model: crm.meeting, id: crm_meeting_regardingsharing0}:
categ_id: crm.categ_meet2
date: !eval time.strftime('%Y-%m-%d 16:04:00')
date_deadline: !eval "(datetime.now() + timedelta(1)).strftime('%Y-%m-%d 00:04:00')"
duration: 8.0
email_from: info@balmerinc.be
location: Gandhinagar
name: Regarding Sharing with other client
partner_address_id: base.res_partner_address_1
partner_id: base.res_partner_9
rrule_type: weekly
section_id: crm.section_sales_department
-
I check the export functionality.
-
!python {model: crm.meeting}: |
self.export_cal(cr, uid, [ref('crm_meeting_regardingsharing0')], context)
import time
vals = []
context.update({'model':'crm.meeting','active_id': ref('crm_meeting_regardingsharing0')})
vals.append({
'date': time.strftime('%Y-%m-%d 16:04:00'),
'create_date': time.strftime('%Y-%m-%d 16:04:00'),
'date_deadline':time.strftime('%Y-%m-%d 20:20:00'),
'id':ref('crm_meeting_regardingsharing0'),
'recurrent_id': time.strftime('%Y-%m-%d 50:00:00'),
})
try:
self.check_import(cr, uid, vals, context)
except:
pass