Skip to content

Commit 60a6461

Browse files
committed
[FIX] account_fiscal_position_type: make test working if other modules create demo fiscal position
1 parent 00fd428 commit 60a6461

File tree

1 file changed

+12
-4
lines changed

1 file changed

+12
-4
lines changed

account_fiscal_position_type/tests/test_module.py

Lines changed: 12 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -47,12 +47,20 @@ def test_chart_template_generation(self):
4747
def test_invoice_fiscal_position_domain(self):
4848
customer_invoice = self.env.ref("account.1_demo_invoice_3").copy()
4949
self.assertEqual(
50-
customer_invoice.suitable_fiscal_position_ids.mapped("type_position_use"),
51-
["sale", "all"],
50+
set(
51+
customer_invoice.suitable_fiscal_position_ids.mapped(
52+
"type_position_use"
53+
)
54+
),
55+
{"sale", "all"},
5256
)
5357

5458
supplier_invoice = self.env.ref("account.1_demo_invoice_5").copy()
5559
self.assertEqual(
56-
supplier_invoice.suitable_fiscal_position_ids.mapped("type_position_use"),
57-
["purchase", "all"],
60+
set(
61+
supplier_invoice.suitable_fiscal_position_ids.mapped(
62+
"type_position_use"
63+
)
64+
),
65+
{"purchase", "all"},
5866
)

0 commit comments

Comments
 (0)