Sha256: a5cc28b2c1e91360c6b81c82f81266b979d7d99fc89e3d0d2d60079f29fcb9e9

Contents?: true

Size: 709 Bytes

Versions: 2

Compression:

Stored size: 709 Bytes

Contents

require 'action_dispatch'
require 'capybara/rails'
require 'capybara/dsl'

module RSpec::Rails
  module IntegrationExampleGroup
    extend ActiveSupport::Concern

    include ActionDispatch::Integration::Runner
    include RSpec::Rails::TestUnitAssertionAdapter
    include ActionDispatch::Assertions
    include Capybara
    include RSpec::Matchers

    module InstanceMethods
      def app
        ::Rails.application
      end

      def last_response
        page
      end
    end

    included do
      before do
        @router = ::Rails.application.routes
      end
    end

    RSpec.configure do |c|
      c.include self, :example_group => { :file_path => /\bspec\/integration\// }
    end
  end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
mir_extensions-1.1.0 spec/support/integration_example_group.rb
mir_extensions-1.0.0 spec/support/integration_example_group.rb