Sha256: f8061534f641628b6db5d59e19c5a1b6c2706dea87cccd0205ff4a9d4a5dfa4a

Contents?: true

Size: 720 Bytes

Versions: 3

Compression:

Stored size: 720 Bytes

Contents

unless ENV['CI']
  require 'simplecov'
  SimpleCov.start do
    add_filter '.bundle'
    add_group 'Silencer', 'lib/silencer'
    add_group 'Specs', 'spec'
  end
end

require 'rack'
require 'rspec'

require 'logger'
require 'stringio'

io = StringIO.new

begin
  require 'rails'
  ::Rails.logger = ::Logger.new(io)
rescue LoadError
  require 'activesupport'
  RAILS_ENV            = 'test'
  RAILS_ROOT           = File.dirname(__FILE__)
  RAILS_DEFAULT_LOGGER = ::Logger.new(io)
  require 'initializer'
end

require 'silencer'

RSpec.configure do |config|
  config.expect_with :rspec do |c|
    c.syntax = :expect
  end

  config.before(:each) do
    allow(::Rails.logger).to receive(:level=).with(anything)
  end

end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
silencer-1.0.0.rc3 spec/spec_helper.rb
silencer-1.0.0.rc2 spec/spec_helper.rb
silencer-1.0.0.rc1 spec/spec_helper.rb