From 46eeb2d31fd6f566b1aa80089b71770ca12f4d1d Mon Sep 17 00:00:00 2001 From: "Ujjvala Collins (OpenERP)" Date: Mon, 31 Jan 2011 10:55:59 +0530 Subject: [PATCH] [FIX] crm, hr_payroll: Corrected date problem in ymls. bzr revid: uco@tinyerp.com-20110131052559-pnmgnhkcop52186r --- addons/crm/test/test_crm_meeting.yml | 2 +- addons/crm/test/test_crm_opportunity.yml | 4 ++-- addons/crm/test/test_crm_phonecall.yml | 6 +++--- addons/hr_payroll/test/payroll_register.yml | 2 +- 4 files changed, 7 insertions(+), 7 deletions(-) diff --git a/addons/crm/test/test_crm_meeting.yml b/addons/crm/test/test_crm_meeting.yml index d7c8a4691d6..d143de3d24a 100644 --- a/addons/crm/test/test_crm_meeting.yml +++ b/addons/crm/test/test_crm_meeting.yml @@ -7,7 +7,7 @@ !record {model: crm.meeting, id: crm_meeting_regardingpresentation0}: categ_id: crm.categ_meet2 date: !eval time.strftime('%Y-%m-%d 16:04:00') - date_deadline: !eval "'%s-%s-%s 00:04:00' %(datetime.now().year,datetime.now().month,datetime.now().day+1)" + date_deadline: !eval "'%s-%s-%d 00:04:00' %(datetime.now().year, (datetime.now()+timedelta(1)).month, (datetime.now()+timedelta(1)).day)" duration: 8.0 email_from: info@balmerinc.be location: Ahmedabad diff --git a/addons/crm/test/test_crm_opportunity.yml b/addons/crm/test/test_crm_opportunity.yml index 3a25db66381..a31c7af8fb2 100644 --- a/addons/crm/test/test_crm_opportunity.yml +++ b/addons/crm/test/test_crm_opportunity.yml @@ -51,7 +51,7 @@ I click on "schedule call" button and select planned date for the call. - !record {model: crm.opportunity2phonecall, id: crm_opportunity2phonecall_abcfuelcounits0}: - date: !eval "'%s-%s-%s 11:15:00' %(datetime.now().year,datetime.now().month,datetime.now().day+1)" + date: !eval "'%s-%s-%s 11:15:00' %(datetime.now().year, (datetime.now()+timedelta(1)).month, (datetime.now()+timedelta(1)).day)" name: 'ABC FUEL CO 829264 - 10002 units' section_id: crm.section_sales_department user_id: base.user_demo @@ -72,7 +72,7 @@ I can see phonecall record after click on "Schedule call" wizard. - !record {model: crm.phonecall, id: crm_phonecall_abcfuelcounits0}: - date: !eval "'%s-%s-%s 11:15:00' %(datetime.now().year,datetime.now().month,datetime.now().day+1)" + date: !eval "'%s-%s-%s 11:15:00' %(datetime.now().year, (datetime.now()+timedelta(1)).month, (datetime.now()+timedelta(1)).day)" duration: 3.0 name: 'ABC FUEL CO 829264 - 10002 units' partner_address_id: base.res_partner_address_1 diff --git a/addons/crm/test/test_crm_phonecall.yml b/addons/crm/test/test_crm_phonecall.yml index 98020d345e6..a5726da8cd7 100644 --- a/addons/crm/test/test_crm_phonecall.yml +++ b/addons/crm/test/test_crm_phonecall.yml @@ -64,8 +64,8 @@ - !record {model: crm.meeting, id: crm_meeting_interviewcall0}: alarm_id: base_calendar.alarm3 - date: !eval "'%s-%s-%s 09:00:00' %(datetime.now().year,datetime.now().month,datetime.now().day+1)" - date_deadline: !eval "'%s-%s-%s 17:00:00' %(datetime.now().year,datetime.now().month,datetime.now().day+1)" + date: !eval "'%s-%s-%s 09:00:00' %(datetime.now().year, (datetime.now()+timedelta(1)).month, (datetime.now()+timedelta(1)).day)" + date_deadline: !eval "'%s-%s-%s 17:00:00' %(datetime.now().year, (datetime.now()+timedelta(1)).month, (datetime.now()+timedelta(1)).day)" duration: 8.0 email_from: info@balmerinc.be name: Interview call @@ -81,7 +81,7 @@ phonecall. - !record {model: crm.phonecall2phonecall, id: crm_phonecall2phonecall_interviewcall0}: - date: !eval "'%s-%s-%s 19:49:00' %(datetime.now().year,datetime.now().month,datetime.now().day+1)" + date: !eval "'%s-%s-%s 19:49:00' %(datetime.now().year, (datetime.now()+timedelta(1)).month, (datetime.now()+timedelta(1)).day)" name: Interview call section_id: crm.section_sales_department user_id: base.user_root diff --git a/addons/hr_payroll/test/payroll_register.yml b/addons/hr_payroll/test/payroll_register.yml index 4a16dafe6ed..ce2284c8cc2 100644 --- a/addons/hr_payroll/test/payroll_register.yml +++ b/addons/hr_payroll/test/payroll_register.yml @@ -26,7 +26,7 @@ I create a payroll register record. - !record {model: hr.payroll.register, id: hr_payroll_register_payroll0}: - date: !eval "'%s-%s-%s' %(datetime.now().year,datetime.now().month,datetime.now().day+1)" + date: !eval "'%s-%s-%s' %(datetime.now().year, (datetime.now()+timedelta(1)).month, (datetime.now()+timedelta(1)).day)" line_ids: - employee_id: hr_payroll.hr_employee_keith0 name: payroll1