mirror of
https://github.com/discourse/discourse.git
synced 2025-02-20 10:56:15 +08:00
parent
2f54dd5e3d
commit
ceb74bef8f
|
@ -128,6 +128,12 @@ describe Notification do
|
|||
Fabricate(:notification)
|
||||
end
|
||||
|
||||
it 'works for partial model instances' do
|
||||
NotificationEmailer.disable
|
||||
partial_user = User.select(:id).find_by(id: Fabricate(:user).id)
|
||||
partial_user.notifications.create!(notification_type: Notification.types[:mentioned], data: '{}')
|
||||
end
|
||||
|
||||
context 'destroy' do
|
||||
let!(:notification) { Fabricate(:notification) }
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user