ENV["RACK_ENV"] = "test"

require "rspec"
require "pry"
require "simplecov"

SimpleCov.start do
  # TODO: increase test coverage!
  minimum_coverage 50
end

require "postqueue"
require "./spec/support/configure_active_record"

logger = Logger.new(File.open("log/test.log", "a"))
logger.level = Logger::INFO

Simple::SQL.logger = Postqueue.logger = logger

RSpec.configure do |config|
  config.run_all_when_everything_filtered = true
  config.filter_run focus: (ENV["CI"] != "true")
  config.expect_with(:rspec) { |c| c.syntax = :expect }
  config.order = "random"

  config.before(:all) {}
  config.after {}
end

ENV["RACK_ENV"] = "test"

require "rspec"
require "pry"
require "simplecov"

SimpleCov.start do
  minimum_coverage 94
  add_filter '/vendor/'
  add_filter '/gems/'
  add_filter '/spec/'
end

require "postqueue"
require "./spec/support/configure_active_record"

logger = Logger.new(File.open("log/test.log", "a"))
logger.level = Logger::INFO

Simple::SQL.logger = Postqueue.logger = logger

RSpec.configure do |config|
  config.run_all_when_everything_filtered = true
  config.filter_run focus: (ENV["CI"] != "true")
  config.expect_with(:rspec) { |c| c.syntax = :expect }
  config.order = "random"

  config.before(:all) {}
  config.after {}
end

Fix test coverage testing on travis by adding filters. So we can set it to 94% again, which is what we get locally
Fix test coverage testing on travis by adding filters. So we can set it to 94% again, which is what we get locally
