You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

19 lines
665 B

  1. # Copyright 2018 ACSONE SA/NV
  2. # License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).
  3. from odoo.addons.product_contract.tests.test_sale_order import TestSaleOrder
  4. class TestSaleOrderPaymentMode(TestSaleOrder):
  5. def setUp(self):
  6. super(TestSaleOrderPaymentMode, self).setUp()
  7. self.payment_mode = self.env['account.payment.mode'].search([], limit=1)
  8. self.sale.payment_mode_id = self.payment_mode
  9. def test_action_confirm_with_payment_mode(self):
  10. self.test_action_confirm()
  11. self.assertEqual(
  12. self.sale.order_line.mapped('contract_id.payment_mode_id'),
  13. self.payment_mode,
  14. )