Sha256: 533d63d70a036d4276e22b3bfce7625ff785cfe6621664875ed314ecf7abc96a

Contents?: true

Size: 296 Bytes

Versions: 22

Compression:

Stored size: 296 Bytes

Contents

FactoryBot.define do
  factory :icon, class: Spree::Icon do
    before(:create) do |icon|
      if icon.respond_to? :attachment
        icon.attachment.attach(io: File.new(Spree::Core::Engine.root + 'spec/fixtures' + 'thinking-cat.jpg'), filename: 'thinking-cat.jpg')
      end
    end
  end
end

Version data entries

22 entries across 22 versions & 1 rubygems

Version Path
spree_core-4.10.1 lib/spree/testing_support/factories/icon_factory.rb
spree_core-4.10.0 lib/spree/testing_support/factories/icon_factory.rb
spree_core-4.9.0 lib/spree/testing_support/factories/icon_factory.rb
spree_core-4.8.3 lib/spree/testing_support/factories/icon_factory.rb
spree_core-4.8.2 lib/spree/testing_support/factories/icon_factory.rb
spree_core-4.7.3 lib/spree/testing_support/factories/icon_factory.rb
spree_core-4.6.6 lib/spree/testing_support/factories/icon_factory.rb
spree_core-4.5.5 lib/spree/testing_support/factories/icon_factory.rb
spree_core-4.5.4 lib/spree/testing_support/factories/icon_factory.rb
spree_core-4.6.5 lib/spree/testing_support/factories/icon_factory.rb
spree_core-4.7.2 lib/spree/testing_support/factories/icon_factory.rb
spree_core-4.7.1 lib/spree/testing_support/factories/icon_factory.rb
spree_core-4.6.4 lib/spree/testing_support/factories/icon_factory.rb
spree_core-4.7.0 lib/spree/testing_support/factories/icon_factory.rb
spree_core-4.6.3 lib/spree/testing_support/factories/icon_factory.rb
spree_core-4.6.2 lib/spree/testing_support/factories/icon_factory.rb
spree_core-4.6.1 lib/spree/testing_support/factories/icon_factory.rb
spree_core-4.6.0 lib/spree/testing_support/factories/icon_factory.rb
spree_core-4.5.3 lib/spree/testing_support/factories/icon_factory.rb
spree_core-4.5.2 lib/spree/testing_support/factories/icon_factory.rb