[FIX] Ensure that the test finds only one bank journal

Previously it was possible to find multiple bank journals,
which caused singleton errors when the test tried to set values
on them.
This commit is contained in:
Atte Isopuro
2018-01-11 12:10:21 +02:00
parent cdf6ab3aca
commit a17b2385c4

View File

@@ -49,7 +49,7 @@ class TestPaymentOrder(TransactionCase):
payment_order = self.env['account.payment.order'].search([])
bank_journal = self.env['account.journal'].search(
[('type', '=', 'bank')])
[('type', '=', 'bank')], limit=1)
# Set journal to allow cancelling entries
bank_journal.update_posted = True