Sha256: 36777dbb2658d5abdf6697b7ab17c124dd1be59ded21045888d3f038251abb10

Contents?: true

Size: 1.04 KB

Versions: 6

Compression:

Stored size: 1.04 KB

Contents

require 'rubygems'

require 'listen'
require 'listen/tcp'

require 'listen/internals/thread_pool'

def ci?
  ENV['CI']
end

if ci?
  require 'coveralls'
  Coveralls.wear!
end

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

# See http://rubydoc.info/gems/rspec-core/RSpec/Core/Configuration
RSpec.configure do |config|
  config.order = :random
  config.filter_run focus: true
  config.run_all_when_everything_filtered = true
  # config.fail_fast = !ci?
  config.expect_with :rspec do |c|
    c.syntax = :expect
  end

  config.mock_with :rspec do |mocks|
    mocks.verify_doubled_constant_names = true
    mocks.verify_partial_doubles = true
  end
end

require 'rspec/retry'
RSpec.configure do |config|
  config.default_retry_count = ci? ? 5 : 1
end

require 'celluloid/rspec'
Thread.abort_on_exception = true
Celluloid.logger.level = Logger::ERROR

RSpec.configuration.before(:each) do
  Listen::Internals::ThreadPool.stop
  Celluloid.boot
end

RSpec.configuration.after(:each) do
  Celluloid.shutdown
  Listen::Internals::ThreadPool.stop
end

Version data entries

6 entries across 6 versions & 1 rubygems

Version Path
listen-2.8.4 spec/spec_helper.rb
listen-2.8.3 spec/spec_helper.rb
listen-2.8.2 spec/spec_helper.rb
listen-2.8.1 spec/spec_helper.rb
listen-2.8.0 spec/spec_helper.rb
listen-2.7.12 spec/spec_helper.rb