File tree Expand file tree Collapse file tree 3 files changed +20
-16
lines changed
Expand file tree Collapse file tree 3 files changed +20
-16
lines changed Original file line number Diff line number Diff line change @@ -46,15 +46,15 @@ Key Capabilities
4646Key Models
4747~~~~~~~~~~
4848
49- +-----------------------------+---------------------------------------+
50- | Model | Description |
51- +=============================+=======================================+
52- | ``spp.import.match `` | Matching rule configuration for a |
53- | | specific model |
54- +-----------------------------+---------------------------------------+
55- | ``spp.import.match.fields `` | Individual field in a rule, with |
56- | | optional sub-field |
57- +-----------------------------+---------------------------------------+
49+ +-----------------------------+---------------------------------------- +
50+ | Model | Description |
51+ +=============================+======================================== +
52+ | ``spp.import.match `` | Matching rule configuration for a |
53+ | | specific model |
54+ +-----------------------------+---------------------------------------- +
55+ | ``spp.import.match.fields `` | Individual field in a rule, with |
56+ | | optional sub-field |
57+ +-----------------------------+---------------------------------------- +
5858
5959Configuration
6060~~~~~~~~~~~~~
Original file line number Diff line number Diff line change @@ -395,8 +395,8 @@ <h1>Key Capabilities</h1>
395395< h1 > Key Models</ h1 >
396396< table border ="1 " class ="docutils ">
397397< colgroup >
398- < col width ="43 % " />
399- < col width ="57 % " />
398+ < col width ="42 % " />
399+ < col width ="58 % " />
400400</ colgroup >
401401< thead valign ="bottom ">
402402< tr > < th class ="head "> Model</ th >
Original file line number Diff line number Diff line change 11# Part of OpenSPP. See LICENSE file for full copyright and licensing details.
22
3+ from odoo import Command
34from odoo .exceptions import ValidationError
45from odoo .tests import TransactionCase , tagged
56
@@ -220,11 +221,14 @@ def test_constrains_duplicate_name(self):
220221 def test_constrains_duplicate_non_relational_field (self ):
221222 """_check_duplicate_fields raises on duplicate non-relational fields on save."""
222223 with self .assertRaises (ValidationError ):
223- self ._create_match_rule (
224- [
225- {"field_id" : self .name_field .id },
226- {"field_id" : self .name_field .id },
227- ]
224+ self .env ["spp.import.match" ].create (
225+ {
226+ "model_id" : self .res_partner_model .id ,
227+ "field_ids" : [
228+ Command .create ({"field_id" : self .name_field .id }),
229+ Command .create ({"field_id" : self .name_field .id }),
230+ ],
231+ }
228232 )
229233
230234 def test_constrains_allows_duplicate_relational_field (self ):
You can’t perform that action at this time.
0 commit comments