Skip to content

Commit

Permalink
[IMP] product_pricelist_supplierinfo: test for non-supplier-info pric…
Browse files Browse the repository at this point in the history
…elist

Add a test for the scenario where the pricelist is not based on the
supplier info, ensuring the price is calculated as expected natively.
  • Loading branch information
CLaurelB committed Jan 8, 2025
1 parent fd4a01c commit 4fc6bf7
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions product_pricelist_supplierinfo/tests/test_product_supplierinfo.py
Original file line number Diff line number Diff line change
Expand Up @@ -327,3 +327,13 @@ def test_pricelist_exclude_supplier_info_discount(self):
self.pricelist._get_product_price(self.product, 1),
10,
)

def test_pricelist_price_not_based_on_supplierinfo(self):
"""Test the scenario where the pricelist is not based on the supplier info,
so the price should be calculated as expected natively.
"""
self.pricelist.item_ids[0].base = "list_price"
self.assertAlmostEqual(
self.pricelist._get_product_price(self.product, 1),
1,
)

0 comments on commit 4fc6bf7

Please sign in to comment.