```ruby
FactoryGirl.define do
  factory :product do
    title 'My favorite product'

    trait :with_stock
    stocks { FactoryGirl.build_list(:stock, 1) }
  end
end
```

Fix syntax in product factory
user
```ruby
FactoryGirl.define do
  factory :product do
    title 'My favorite product'

    trait :with_stock do
      stocks { build_list(:stock, 1) }
    end
  end
end
```
assistant