mirror of
https://github.com/bringout/oca-ocb-test.git
synced 2026-04-24 09:02:05 +02:00
Initial commit: Test packages
This commit is contained in:
commit
080accd21c
338 changed files with 32413 additions and 0 deletions
|
|
@ -0,0 +1,43 @@
|
|||
# -*- coding: utf-8 -*-
|
||||
# Part of Odoo. See LICENSE file for full copyright and licensing details.
|
||||
|
||||
from datetime import datetime
|
||||
|
||||
from odoo.addons.crm.tests.common import TestCrmCommon
|
||||
from odoo.addons.crm_iap_mine.tests.common import MockIAPReveal # MockIAPEnrich
|
||||
from odoo.addons.website.tests.test_website_visitor import MockVisitor
|
||||
|
||||
|
||||
class TestCrmFullCommon(TestCrmCommon, MockIAPReveal, MockVisitor):
|
||||
|
||||
@classmethod
|
||||
def setUpClass(cls):
|
||||
super(TestCrmFullCommon, cls).setUpClass()
|
||||
cls._init_mail_gateway()
|
||||
cls._activate_multi_company()
|
||||
|
||||
# Context data: dates
|
||||
# ------------------------------------------------------------
|
||||
|
||||
# Mock dates to have reproducible computed fields based on time
|
||||
cls.reference_now = datetime(2022, 1, 1, 10, 0, 0)
|
||||
cls.reference_today = datetime(2022, 1, 1)
|
||||
|
||||
# Customers
|
||||
# ------------------------------------------------------------
|
||||
|
||||
country_be = cls.env.ref('base.be')
|
||||
cls.env['res.lang']._activate_lang('fr_BE')
|
||||
|
||||
cls.partners = cls.env['res.partner'].create([
|
||||
{'country_id': country_be.id,
|
||||
'email': 'partner.email.%02d@test.example.com' % idx,
|
||||
'function': 'Noisy Customer',
|
||||
'lang': 'fr_BE',
|
||||
'mobile': '04569999%02d' % idx,
|
||||
'name': 'PartnerCustomer',
|
||||
'phone': '04560000%02d' % idx,
|
||||
'street': 'Super Street, %092d' % idx,
|
||||
'zip': '1400',
|
||||
} for idx in range(0, 10)
|
||||
])
|
||||
Loading…
Add table
Add a link
Reference in a new issue