mirror of
https://github.com/bringout/oca-technical.git
synced 2026-04-18 13:52:05 +02:00
Initial commit: OCA Technical packages (595 packages)
This commit is contained in:
commit
2cc02aac6e
24950 changed files with 2318079 additions and 0 deletions
|
|
@ -0,0 +1 @@
|
|||
from . import test_web_widget_pattern
|
||||
|
|
@ -0,0 +1,14 @@
|
|||
# Copyright 2024 Hunki Enterprises BV
|
||||
# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl-3.0)
|
||||
|
||||
from odoo.tests.common import TransactionCase
|
||||
|
||||
|
||||
class TestWebWidgetPattern(TransactionCase):
|
||||
def test_fields_get(self):
|
||||
ResPartner = self.env["res.partner"]
|
||||
ResPartner._fields["street2"].pattern = "[0-9]"
|
||||
field_description = ResPartner.get_views(
|
||||
[(self.env.ref("base.view_partner_form").id, "form")]
|
||||
)["models"]["res.partner"]["street2"]
|
||||
self.assertEqual(field_description["pattern"], "[0-9]")
|
||||
Loading…
Add table
Add a link
Reference in a new issue