Send '0', not 'null', to perf platform if no notifications are sent

This commit is contained in:
Katie Smith
2017-08-30 16:02:30 +01:00
parent a1a5fdedb1
commit 49a6bfc06b
2 changed files with 10 additions and 3 deletions

View File

@@ -85,3 +85,10 @@ def test_get_total_notifications_counts_messages_that_have_not_sent(sample_templ
result = dao_get_total_notifications_sent_per_day_for_perfomance_platform(date(2016, 10, 18), date(2016, 10, 19))
assert result.messages_total == 1
assert result.messages_within_10_secs == 0
@freeze_time('2016-10-18T10:00')
def test_get_total_notifications_returns_zero_if_no_data(notify_db_session):
result = dao_get_total_notifications_sent_per_day_for_perfomance_platform(date(2016, 10, 18), date(2016, 10, 19))
assert result.messages_total == 0
assert result.messages_within_10_secs == 0