Browse Source

[12.0][IMP] - Add failing test for next invoice date before the last date invoiced

pull/447/head
sbejaoui 5 years ago
parent
commit
294f92b7ac
  1. 9
      contract/tests/test_contract.py

9
contract/tests/test_contract.py

@ -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',
})
Loading…
Cancel
Save