OSDN Git Service

fix js manifest
[pettanr/pettanr.git] / spec / factories / author.rb
index 85f1ae0..6274e25 100644 (file)
@@ -11,7 +11,15 @@ FactoryGirl.define do
         create_list(:scroll_hello, evaluator.scrolls_count, author: author)\r
       end\r
     end\r
+    trait :with_contents do\r
+      after(:create) do |author, evaluator|\r
+        panel_hello = create(:panel_hello, author: author)\r
+        scroll_hello = create(:scroll_hello, author: author)\r
+        scroll_hello_panel_hello = create(:scroll_hello_panel_hello, scroll: scroll_hello, panel: panel_hello)\r
+      end\r
+    end\r
     factory :yas_with_scrolls, traits: [:with_scrolls]\r
+    factory :yas_with_contents , traits: [:with_contents]\r
   end\r
   factory :author_itojun, :class => Author do |i|\r
     i.name 'itojun'\r