Sha256: 049f4c7890d26ea845b30b1af301a84e5ac082224c5c0574976284b6751e01d1

Contents?: true

Size: 633 Bytes

Versions: 4

Compression:

Stored size: 633 Bytes

Contents

require "magic_test/support"
require "pry"
require "pry-stack_explorer"

module MagicTest
  class Engine < Rails::Engine
    config.after_initialize do
      if ENV["MAGIC_TEST"].present?
        if defined? ActionDispatch::SystemTestCase
          ActionDispatch::SystemTestCase.include MagicTest::Support
        end

        if defined? ActionDispatch::IntegrationTest
          ActionDispatch::IntegrationTest.include MagicTest::Support
        end

        if defined? RSpec
          RSpec.configure do |config|
            config.include MagicTest::Support, type: :system
          end
        end
      end
    end
  end
end

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
magic_test-0.0.9 lib/magic_test/engine.rb
magic_test-0.0.7 lib/magic_test/engine.rb
magic_test-0.0.6 lib/magic_test/engine.rb
magic_test-0.0.5 lib/magic_test/engine.rb