Update existing tests for new CLIN logic

- Factory adds total_amount field, which is always greater than obligated
field
- add total_amount field on tests that create TOs manually
- update tests that calculate total_contract_amount and
total_obligated_amount
This commit is contained in:
graham-dds
2019-09-11 11:52:25 -04:00
parent 0abd46eb4f
commit 2af0a2ecaf
5 changed files with 21 additions and 5 deletions

View File

@@ -291,8 +291,8 @@ class CLINFactory(Base):
number = factory.LazyFunction(random_task_order_number)
start_date = datetime.date.today()
end_date = factory.LazyFunction(random_future_date)
total_amount = factory.LazyFunction(lambda *args: random.randint(100, 999999))
obligated_amount = factory.LazyFunction(lambda *args: random.randint(100, 999999))
total_amount = factory.LazyFunction(lambda *args: random.randint(50000, 999999))
obligated_amount = factory.LazyFunction(lambda *args: random.randint(100, 50000))
jedi_clin_type = factory.LazyFunction(
lambda *args: random.choice(list(clin.JEDICLINType))
)