Browse Source

make test_configuration_helper installable and set name on inheritance

pull/1261/head
Timon Tschanz 6 years ago
committed by Akim Juillerat
parent
commit
4f34306682
  1. 1
      configuration_helper/models/config.py
  2. 2
      test_configuration_helper/__manifest__.py
  3. 1
      test_configuration_helper/models.py
  4. 1
      test_configuration_helper/tests/test_config.py

1
configuration_helper/models/config.py

@ -30,7 +30,6 @@ class AbstractConfigSettings(models.AbstractModel):
@api.model
def _setup_base(self):
import pdb; pdb.set_trace()
cls = type(self)
super(AbstractConfigSettings, self)._setup_base()
if not cls._companyObject:

2
test_configuration_helper/__manifest__.py

@ -7,7 +7,7 @@
'category': 'Tests',
'depends': ['configuration_helper'],
'website': 'https://github.com/OCA/server-tools',
'installable': False,
'installable': True,
'auto_install': False,
'license': 'AGPL-3',
'application': False,

1
test_configuration_helper/models.py

@ -13,6 +13,7 @@ class ResCompany(models.Model):
class MyConfigA(models.TransientModel):
_name = 'res.config.settings'
_inherit = ['res.config.settings', 'abstract.config.settings']
_prefix = 'prefix_a_'
_companyObject = ResCompany

1
test_configuration_helper/tests/test_config.py

@ -6,7 +6,6 @@ import odoo.tests.common as common
class TestAbstractSettings(common.TransactionCase):
def setUp(self):
import pdb; pdb.set_trace()
super(TestAbstractSettings, self).setUp()
self.partner_id = self.ref('base.res_partner_12')
self.company = self.env.ref('base.main_company')

Loading…
Cancel
Save