2018-05-07 16:47:29 -07:00
|
|
|
# frozen_string_literal: true
|
|
|
|
|
|
2017-03-03 15:07:54 +01:00
|
|
|
require_relative 'external_request'
|
|
|
|
|
|
|
|
|
|
RSpec.configure do |config|
|
|
|
|
|
|
|
|
|
|
config.before(:suite) do
|
|
|
|
|
if ENV['OSEM_FACTORY_LINT'] != 'false'
|
2017-06-14 02:46:39 +05:30
|
|
|
DatabaseCleaner.strategy = :transaction
|
|
|
|
|
DatabaseCleaner.clean_with(:truncation)
|
|
|
|
|
begin
|
|
|
|
|
DatabaseCleaner.start
|
|
|
|
|
mock_commercial_request
|
2018-09-03 20:44:39 +02:00
|
|
|
FactoryBot.lint
|
2017-06-14 02:46:39 +05:30
|
|
|
ensure
|
|
|
|
|
DatabaseCleaner.clean
|
|
|
|
|
end
|
2017-03-03 15:07:54 +01:00
|
|
|
end
|
|
|
|
|
end
|
|
|
|
|
end
|