Sha256: 3c92cfd6a5b38cd2f511978dbb26d616711c25db28881c7d81cf052aadef6665

Contents?: true

Size: 1.12 KB

Versions: 12

Compression:

Stored size: 1.12 KB

Contents

require 'simplecov'
SimpleCov.start do
  add_filter "/test/"
  add_filter "/examples/"
end

require 'datasift'
require 'minitest'

require File.expand_path('./../../examples/auth', __FILE__)
require 'minitest/autorun'
require 'webmock/minitest'
require 'multi_json'
require 'ostruct'
require 'vcr'

STATUS = OpenStruct.new(
  valid: 200,
  created: 201,
  accepted: 202,
  no_content: 204,
  bad_request: 400,
  not_found: 404,
  conflict: 409,
  gone: 410
)

def fixture_path
  File.expand_path('../fixtures', __FILE__)
end

def fixture(file)
  File.new(fixture_path + '/' + file)
end

VCR.configure do |c|
  c.cassette_library_dir = File.join(File.dirname(__FILE__), 'fixtures', 'cassettes')
  c.default_cassette_options = {
    record:                     :new_episodes,
    decode_compressed_response: true,
    serialize_with:             :json,
    preserve_exact_body_bytes:  true
  }
  c.hook_into :webmock
  c.filter_sensitive_data('<USERNAME:API_KEY>') { |interaction| interaction.request.headers['Authorization'].first }
  c.filter_sensitive_data('<BASE64_STRING>') { |interaction| interaction.request.body }
end

include WebMock::API

Version data entries

12 entries across 12 versions & 1 rubygems

Version Path
datasift-3.7.2 test/test_helper.rb
datasift-3.5.2 test/test_helper.rb
datasift-3.5.1 test/test_helper.rb
datasift-3.7.1 test/test_helper.rb
datasift-3.7.0 test/test_helper.rb
datasift-3.6.2 test/test_helper.rb
datasift-3.6.1 test/test_helper.rb
datasift-3.6.0 test/test_helper.rb
datasift-3.5.0 test/test_helper.rb
datasift-3.4.0 test/test_helper.rb
datasift-3.3.0 test/test_helper.rb
datasift-3.2.0 test/test_helper.rb