Sha256: c13b53f846bcce75bb36515b1eeeb0ea8fce929c05088a374bad7c48a70bc7cd

Contents?: true

Size: 703 Bytes

Versions: 33

Compression:

Stored size: 703 Bytes

Contents

# frozen_string_literal: true

require 'spree/testing_support/factory_bot'
Spree::TestingSupport::FactoryBot.when_cherry_picked do
  Spree::TestingSupport::FactoryBot.deprecate_cherry_picking

  require 'spree/testing_support/factories/store_credit_category_factory'
  require 'spree/testing_support/factories/store_credit_type_factory'
  require 'spree/testing_support/factories/user_factory'
end

FactoryBot.define do
  factory :store_credit, class: 'Spree::StoreCredit' do
    user
    association :created_by, factory: :user
    association :category, factory: :store_credit_category
    amount { 150.00 }
    currency { "USD" }
    association :credit_type, factory: :primary_credit_type
  end
end

Version data entries

33 entries across 33 versions & 1 rubygems

Version Path
solidus_core-3.1.9 lib/spree/testing_support/factories/store_credit_factory.rb
solidus_core-3.1.8 lib/spree/testing_support/factories/store_credit_factory.rb
solidus_core-3.0.8 lib/spree/testing_support/factories/store_credit_factory.rb
solidus_core-3.0.7 lib/spree/testing_support/factories/store_credit_factory.rb
solidus_core-2.11.17 lib/spree/testing_support/factories/store_credit_factory.rb
solidus_core-3.1.7 lib/spree/testing_support/factories/store_credit_factory.rb
solidus_core-2.11.16 lib/spree/testing_support/factories/store_credit_factory.rb
solidus_core-3.0.6 lib/spree/testing_support/factories/store_credit_factory.rb
solidus_core-3.1.6 lib/spree/testing_support/factories/store_credit_factory.rb
solidus_core-2.11.15 lib/spree/testing_support/factories/store_credit_factory.rb
solidus_core-2.11.14 lib/spree/testing_support/factories/store_credit_factory.rb
solidus_core-3.0.5 lib/spree/testing_support/factories/store_credit_factory.rb
solidus_core-3.1.5 lib/spree/testing_support/factories/store_credit_factory.rb
solidus_core-2.11.13 lib/spree/testing_support/factories/store_credit_factory.rb
solidus_core-3.0.4 lib/spree/testing_support/factories/store_credit_factory.rb
solidus_core-3.1.4 lib/spree/testing_support/factories/store_credit_factory.rb
solidus_core-2.11.12 lib/spree/testing_support/factories/store_credit_factory.rb
solidus_core-3.0.3 lib/spree/testing_support/factories/store_credit_factory.rb
solidus_core-3.1.3 lib/spree/testing_support/factories/store_credit_factory.rb
solidus_core-3.1.2 lib/spree/testing_support/factories/store_credit_factory.rb