diff options
author | Patrick J Cherry <patrick@bytemark.co.uk> | 2011-08-19 16:28:37 +0100 |
---|---|---|
committer | Patrick J Cherry <patrick@bytemark.co.uk> | 2011-08-19 16:28:37 +0100 |
commit | cdb78656916abe5adb946a25b913cda7785a42de (patch) | |
tree | 0f656d639868c2ac8d8a14a5370ab8f2263092dc /test/tc_mauve_alert_changed.rb | |
parent | 8d209c0f6a1b3c47f9bc55b6f63cb14bfa935162 (diff) |
HTML now sanitised on save.
Added History tests
Default polling interval now 5s, 0s for Timer/UDPServer
Fixed note entry for alert page.
Diffstat (limited to 'test/tc_mauve_alert_changed.rb')
-rw-r--r-- | test/tc_mauve_alert_changed.rb | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/test/tc_mauve_alert_changed.rb b/test/tc_mauve_alert_changed.rb index 52f1f25..0e57120 100644 --- a/test/tc_mauve_alert_changed.rb +++ b/test/tc_mauve_alert_changed.rb @@ -67,6 +67,21 @@ EOF AlertChanged.all.each{|ac| ac.poll} end + # OK now clear the alert, send one notification and set an alert_changed. + alert.clear! + notifications += 1 + reminders += 1 + assert_equal(notifications, Server.instance.notification_buffer.length) + assert_equal(reminders, AlertChanged.count) + + Timecop.freeze(Time.now + 10.minutes) + AlertChanged.all.each{|ac| ac.poll} + # + # Send NO MORE notifications. + # + assert_equal(notifications, Server.instance.notification_buffer.length) + assert_equal(reminders, AlertChanged.count) + end |