```ruby
FactoryGirl.define do
  factory :subscription, class: Spree::Subscription do
    user { create :user }
    address { create :address }
    subscription_product { create :subscription_product }
    limit 12
  end
end
```

Fix failing test * Create a product before create a subscription factory
user
```ruby
FactoryGirl.define do
  factory :subscription, class: Spree::Subscription do
    before(:create) do
      create(:product) if Spree::Product.unsubscribable.count == 0
    end

    user { create :user }
    address { create :address }
    subscription_product { create :subscription_product }
    limit 12
  end
end
```
assistant