Sha256: 01cf2b0a1b5e8dc955f7f0bb02d74750536362e0113170bcc764dffe2c7137d6

Contents?: true

Size: 1021 Bytes

Versions: 5

Compression:

Stored size: 1021 Bytes

Contents

# A basic feature_helper to be included as the starting point for extensions
#
# Can be required from an extension's spec/feature_helper.rb
#
#     require 'solidus_support/extension/feature_helper'
#

require 'solidus_support/extension/rails_helper'

require 'capybara-screenshot/rspec'
require 'capybara/poltergeist'

Capybara.register_driver :poltergeist do |app|
  Capybara::Poltergeist::Driver.new(app, js_errors: true, timeout: 90)
end

Capybara.javascript_driver = :poltergeist
Capybara.default_max_wait_time = 10

require 'spree/testing_support/capybara_ext'

RSpec.configure do |config|
  config.when_first_matching_example_defined(type: :feature) do
    config.before :suite do
      # Preload assets
      if Rails.application.respond_to?(:precompiled_assets)
        Rails.application.precompiled_assets
      else
        # For older sprockets 2.x
        Rails.application.config.assets.precompile.each do |asset|
          Rails.application.assets.find_asset(asset)
        end
      end
    end
  end
end

Version data entries

5 entries across 5 versions & 2 rubygems

Version Path
solidus_support_devise_token_auth-0.2.2.2 lib/solidus_support/extension/feature_helper.rb
solidus_support_devise_token_auth-0.2.2.1 lib/solidus_support/extension/feature_helper.rb
solidus_support_devise_token_auth-0.2.2.0 lib/solidus_support/extension/feature_helper.rb
solidus_support_devise_token_auth-0.2.2 lib/solidus_support/extension/feature_helper.rb
solidus_support-0.2.2 lib/solidus_support/extension/feature_helper.rb