diff --git a/spec/factories/news.rb b/spec/factories/news.rb new file mode 100644 index 0000000..1504bc4 --- /dev/null +++ b/spec/factories/news.rb @@ -0,0 +1,11 @@ +FactoryBot.define do + + factory :news do + project + sequence(:title) {|n| 'News #' + n.to_s } + summary { 'Lorem Ipsum is simply dummy text' } + description { 'Lorem Ipsum is simply dummy text of the printing and typesetting industry.' } + author + end + +end diff --git a/spec/factory_spec.rb b/spec/factory_spec.rb index 4c585fe..f7c6c90 100644 --- a/spec/factory_spec.rb +++ b/spec/factory_spec.rb @@ -10,6 +10,10 @@ def factories(names) it { FactoryBot.lint factories(%i[issue issue_custom_field journal tracker issue_status issue_priority]) } end + context "News" do + it { FactoryBot.lint factories(%i[news]) } + end + context "Project" do it { FactoryBot.lint factories(%i[project role]) } end