From bf666148997c5a446b48b37918434ac218952601 Mon Sep 17 00:00:00 2001 From: Ben Thorner Date: Wed, 27 Apr 2022 13:55:07 +0100 Subject: [PATCH] Fix incorrect billable_units for email test data Emails always retain the default of "0" [^1]. [^1]: https://github.com/alphagov/notifications-api/blob/a4fe11a3aaa75d72cf3f0d5b1e8283fbb6622171/app/models.py#L1441 --- tests/app/dao/test_ft_billing_dao.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tests/app/dao/test_ft_billing_dao.py b/tests/app/dao/test_ft_billing_dao.py index 7de1d0c52..5a162a1d3 100644 --- a/tests/app/dao/test_ft_billing_dao.py +++ b/tests/app/dao/test_ft_billing_dao.py @@ -49,7 +49,7 @@ def set_up_yearly_data(): # doesn't accidentally bleed over into them for dt in (date(2016, 3, 31), date(2017, 4, 1)): create_ft_billing(bst_date=dt, template=sms_template, rate=0.163) - create_ft_billing(bst_date=dt, template=email_template, rate=0) + create_ft_billing(bst_date=dt, template=email_template, rate=0, billable_unit=0) create_ft_billing(bst_date=dt, template=letter_template, rate=0.34, postage='second') create_ft_billing(bst_date=dt, template=letter_template, rate=0.31, postage='second') @@ -60,7 +60,7 @@ def set_up_yearly_data(): dt = start_date + timedelta(days=n) create_ft_billing(bst_date=dt, template=sms_template, rate=0.162) - create_ft_billing(bst_date=dt, template=email_template, rate=0) + create_ft_billing(bst_date=dt, template=email_template, rate=0, billable_unit=0) create_ft_billing(bst_date=dt, template=letter_template, rate=0.33, postage='second') create_ft_billing(bst_date=dt, template=letter_template, rate=0.30, postage='second')