Fix notifiable in-app topic specs
These specs had never been tested before and were always broken.
This commit is contained in:
@@ -21,6 +21,12 @@ FactoryBot.define do
|
||||
sequence(:title) { |n| "Topic title #{n}" }
|
||||
sequence(:description) { |n| "Description as comment #{n}" }
|
||||
association :author, factory: :user
|
||||
|
||||
trait :with_community do
|
||||
community { create(:proposal).community }
|
||||
end
|
||||
|
||||
factory :topic_with_community, traits: [:with_community]
|
||||
end
|
||||
|
||||
factory :related_content do
|
||||
|
||||
@@ -3,7 +3,7 @@ require "rails_helper"
|
||||
describe "Topics" do
|
||||
|
||||
context "Concerns" do
|
||||
it_behaves_like "notifiable in-app", Topic
|
||||
it_behaves_like "notifiable in-app", :topic_with_community
|
||||
end
|
||||
|
||||
context "New" do
|
||||
|
||||
Reference in New Issue
Block a user