summaryrefslogtreecommitdiff
path: root/odoo/addons/test_documentation_examples/tests/test_inheritance.py
diff options
context:
space:
mode:
authorRaphael Collet <rco@openerp.com>2016-09-02 15:58:39 +0200
committerRaphael Collet <rco@openerp.com>2016-09-02 17:28:12 +0200
commit9e64f9f9514194d74e166b032add8511182f2677 (patch)
tree5086710c04c6b923be18a6d1d97b3f0f3a2a9c4a /odoo/addons/test_documentation_examples/tests/test_inheritance.py
parent11812b0b9e82b2b1b9041d8250ce01e7b4a5f7ee (diff)
[REF] openerp: move `openerp` to `odoo`
Diffstat (limited to 'odoo/addons/test_documentation_examples/tests/test_inheritance.py')
-rw-r--r--odoo/addons/test_documentation_examples/tests/test_inheritance.py14
1 files changed, 14 insertions, 0 deletions
diff --git a/odoo/addons/test_documentation_examples/tests/test_inheritance.py b/odoo/addons/test_documentation_examples/tests/test_inheritance.py
new file mode 100644
index 00000000000..699c6b98ed2
--- /dev/null
+++ b/odoo/addons/test_documentation_examples/tests/test_inheritance.py
@@ -0,0 +1,14 @@
+# -*- coding: utf-8 -*-
+# Part of Odoo. See LICENSE file for full copyright and licensing details.
+
+from odoo.tests import common
+
+class TestBasicInheritance(common.TransactionCase):
+ def test_inherit_method(self):
+ env = self.env
+
+ a = env['inheritance.0'].create({'name': 'A'})
+ b = env['inheritance.1'].create({'name': 'B'})
+
+ self.assertEqual(a.call(), "This is model 0 record A")
+ self.assertEqual(b.call(), "This is model 1 record B")