Sha256: 81b4c8c2de08ff6ddd48372c91b1480669c772872b5b60f7642cbffbf93008b8

Contents?: true

Size: 768 Bytes

Versions: 5

Compression:

Stored size: 768 Bytes

Contents

require 'database_cleaner'

# Filter out Minitest backtrace while allowing backtrace from other libraries
# to be shown.
Minitest.backtrace_filter = Minitest::BacktraceFilter.new

# Load support files
Dir["#{File.dirname(__FILE__)}/support/**/*.rb"].each { |f| require f }

DatabaseCleaner.strategy = :transaction
DatabaseCleaner.clean_with :truncation
Dragonfly.app.use_datastore :memory

class ActiveSupport::TestCase
  before :each do
    DatabaseCleaner.start
    PushType.config.root_nodes = :all
    PushType.config.unexposed_nodes = []
  end

  after :each do
    DatabaseCleaner.clean
  end
  # Add more helper methods to be used by all tests here...
end

class ActionController::TestCase
  before :each do
    @routes = PushType::Core::Engine.routes
  end
end

Version data entries

5 entries across 5 versions & 1 rubygems

Version Path
push_type_core-0.3.3 lib/push_type/testing/setup.rb
push_type_core-0.3.1 lib/push_type/testing/setup.rb
push_type_core-0.2.1 lib/push_type/testing/setup.rb
push_type_core-0.2.0 lib/push_type/testing/setup.rb
push_type_core-0.2.0.beta2 lib/push_type/testing/setup.rb