File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -659,12 +659,15 @@ def test_x_subscription_oca_pricelist_related_2(self):
659659 self .pricelist_l3 .currency_id = self .env .ref ("base.THB" )
660660 self .sub_line .sale_subscription_id .pricelist_id = self .pricelist_l3
661661 res = self .sub_line ._get_display_price (self .product_1 )
662+ conversion_rate = self .env .company .currency_id ._get_conversion_rate (
663+ self .env .company .currency_id ,
664+ self .pricelist_l3 .currency_id ,
665+ self .env .company ,
666+ fields .Date .today (),
667+ )
662668 self .assertAlmostEqual (
663669 int (res ),
664- round (
665- self .product_1 .standard_price
666- * self .pricelist_l3 .currency_id .rate_ids [:1 ].company_rate
667- ),
670+ round (self .product_1 .standard_price * conversion_rate ),
668671 )
669672 self .sub_line .product_uom_qty = 300
670673 res = self .sub_line .read (["discount" ])
You can’t perform that action at this time.
0 commit comments