Commit b5809822 authored by http://jneen.net/'s avatar http://jneen.net/

add a spec for never emailing the ghost user

parent 7416fbb3
...@@ -87,6 +87,14 @@ describe NotificationService, :mailer do ...@@ -87,6 +87,14 @@ describe NotificationService, :mailer do
it 'sends email to key owner' do it 'sends email to key owner' do
expect { notification.new_key(key) }.to change { ActionMailer::Base.deliveries.size }.by(1) expect { notification.new_key(key) }.to change { ActionMailer::Base.deliveries.size }.by(1)
end end
it 'never emails the ghost user' do
key.user = User.ghost
notification.new_key(key)
should_not_email_anyone
end
end end
end end
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment