Sha256: c532acdd34536eb15c7a4ab44f4e940654d5846b6a26ae830ffcb3e1fd2d9399

Contents?: true

Size: 1.28 KB

Versions: 5

Compression:

Stored size: 1.28 KB

Contents

require 'simplecov'
require 'coveralls'

SimpleCov.formatter = SimpleCov::Formatter::MultiFormatter[
  SimpleCov::Formatter::HTMLFormatter,
  Coveralls::SimpleCov::Formatter
]

SimpleCov.start do
  add_filter '/spec/'
  minimum_coverage(99.35)
end

require 'twitter'
require 'rspec'
require 'stringio'
require 'tempfile'
require 'timecop'
require 'webmock/rspec'

WebMock.disable_net_connect!(:allow => 'coveralls.io')

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

def a_delete(path)
  a_request(:delete, Twitter::REST::Client::ENDPOINT + path)
end

def a_get(path)
  a_request(:get, Twitter::REST::Client::ENDPOINT + path)
end

def a_post(path)
  a_request(:post, Twitter::REST::Client::ENDPOINT + path)
end

def a_put(path)
  a_request(:put, Twitter::REST::Client::ENDPOINT + path)
end

def stub_delete(path)
  stub_request(:delete, Twitter::REST::Client::ENDPOINT + path)
end

def stub_get(path)
  stub_request(:get, Twitter::REST::Client::ENDPOINT + path)
end

def stub_post(path)
  stub_request(:post, Twitter::REST::Client::ENDPOINT + path)
end

def stub_put(path)
  stub_request(:put, Twitter::REST::Client::ENDPOINT + path)
end

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

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

Version data entries

5 entries across 5 versions & 1 rubygems

Version Path
twitter-5.5.1 spec/helper.rb
twitter-5.5.0 spec/helper.rb
twitter-5.4.1 spec/helper.rb
twitter-5.4.0 spec/helper.rb
twitter-5.3.1 spec/helper.rb