discourse/spec/fabricators/notification_fabricator.rb
2013-03-01 21:16:36 +03:00

18 lines
558 B
Ruby

Fabricator(:notification) do
notification_type Notification.types[:mentioned]
data '{"poison":"ivy","killer":"croc"}'
user
topic {|attrs| Fabricate(:topic, user: attrs[:user] ) }
end
Fabricator(:quote_notification, from: :notification) do
notification_type Notification.types[:quoted]
user
topic {|attrs| Fabricate(:topic, user: attrs[:user] ) }
end
Fabricator(:private_message_notification, from: :notification) do
notification_type Notification.types[:private_message]
user
topic {|attrs| Fabricate(:topic, user: attrs[:user] ) }
end