mirror of
https://github.com/OCA/contract.git
synced 2025-02-13 17:57:24 +02:00
[12.0][IMP] - Add failing test for next invoice date before the last date invoiced
This commit is contained in:
committed by
Francisco Ivan Anton Prieto
parent
5f5a5eb8d4
commit
7e55756ddd
@@ -2280,3 +2280,12 @@ class TestContract(TestContractBase):
|
||||
self.assertTrue(self.acct_line.recurring_next_date)
|
||||
self.acct_line.stop(self.acct_line.last_date_invoiced)
|
||||
self.assertFalse(self.acct_line.recurring_next_date)
|
||||
|
||||
def test_check_last_date_invoiced_before_next_invoice_date(self):
|
||||
with self.assertRaises(ValidationError):
|
||||
self.acct_line.write({
|
||||
'date_start': '2019-01-01',
|
||||
'date_end': '2019-12-01',
|
||||
'recurring_next_date': '2019-01-01',
|
||||
'last_date_invoiced': '2019-06-01',
|
||||
})
|
||||
|
||||
Reference in New Issue
Block a user