add tests for monthly notification stats

This commit is contained in:
Leo Hemsted
2018-07-03 14:36:53 +01:00
parent 00e9fee471
commit be52adc68f
3 changed files with 163 additions and 6 deletions

View File

@@ -568,7 +568,7 @@ def create_ft_billing(bst_date,
def create_ft_notification_status(
bst_date,
notification_type,
notification_type='sms',
service=None,
template=None,
job=None,
@@ -576,9 +576,12 @@ def create_ft_notification_status(
notification_status='delivered',
count=1
):
if not service:
service = create_service()
if not template:
if template:
service = template.service
notification_type = template.template_type
else:
if not service:
service = create_service()
template = create_template(service=service, template_type=notification_type)
data = FactNotificationStatus(