Rename Message to Notification

This commit is contained in:
Artur Beljajev 2018-08-23 20:03:03 +03:00
parent 5ba2170324
commit 8765baf319
32 changed files with 243 additions and 229 deletions

View file

@ -0,0 +1,27 @@
require 'test_helper'
class NotificationTest < ActiveSupport::TestCase
setup do
@notification = notifications(:greeting)
end
def test_valid
assert @notification.valid?
end
def test_invalid_without_body
@notification.body = nil
assert @notification.invalid?
end
def test_invalid_without_registrar
@notification.registrar = nil
assert @notification.invalid?
end
def test_dequeue
@notification.dequeue
@notification.reload
assert_not @notification.queued?
end
end