Skip to content

Commit

Permalink
[FIX] product_abc_classification: Fix tests
Browse files Browse the repository at this point in the history
  • Loading branch information
rousseldenis committed Sep 18, 2023
1 parent fdb1105 commit 70beefc
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 1 deletion.
7 changes: 6 additions & 1 deletion product_abc_classification/tests/common.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
# Copyright 2021 ACSONE SA/NV
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).

from odoo.fields import Command
from odoo.tests.common import TransactionCase


Expand Down Expand Up @@ -118,6 +119,10 @@ def _create_variant(cls, size_value):
return cls.env["product.product"].create(
{
"product_tmpl_id": cls.product_template.id,
"product_template_attribute_value_ids": [(6, 0, size_value.ids)],
"product_template_attribute_value_ids": [
Command.set(
size_value.pav_attribute_line_ids.product_template_value_ids.ids
)
],
}
)
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
from psycopg2 import IntegrityError

from odoo.exceptions import ValidationError
from odoo.tools.misc import mute_logger

from .common import ABCClassificationCase

Expand Down Expand Up @@ -185,6 +186,7 @@ def test_04(self):
}
)

@mute_logger("odoo.sql_db")
def test_05(self):
"""
Data:
Expand Down Expand Up @@ -282,6 +284,7 @@ def test_06(self):
)
self.assertTrue(new_profile)

@mute_logger("odoo.sql_db")
def test_07(self):
"""
Data:
Expand Down

0 comments on commit 70beefc

Please sign in to comment.