Sha256: 99d1a745fc68a27a06ab0fe8874e4ce6dc7e36095a8bbfc3fd31392ecbc87206
Contents?: true
Size: 1.46 KB
Versions: 1
Compression:
Stored size: 1.46 KB
Contents
ENV['THOR_COLUMNS'] = "80" require 'simplecov' require 'coveralls' SimpleCov.formatter = SimpleCov::Formatter::MultiFormatter[ SimpleCov::Formatter::HTMLFormatter, Coveralls::SimpleCov::Formatter ] SimpleCov.start require 't' require 'multi_json' require 'rspec' require 'timecop' require 'webmock/rspec' RSpec.configure do |config| config.expect_with :rspec do |c| c.syntax = :expect end end def a_delete(path, endpoint='https://api.twitter.com') a_request(:delete, endpoint + path) end def a_get(path, endpoint='https://api.twitter.com') a_request(:get, endpoint + path) end def a_post(path, endpoint='https://api.twitter.com') a_request(:post, endpoint + path) end def a_put(path, endpoint='https://api.twitter.com') a_request(:put, endpoint + path) end def stub_delete(path, endpoint='https://api.twitter.com') stub_request(:delete, endpoint + path) end def stub_get(path, endpoint='https://api.twitter.com') stub_request(:get, endpoint + path) end def stub_post(path, endpoint='https://api.twitter.com') stub_request(:post, endpoint + path) end def stub_put(path, endpoint='https://api.twitter.com') stub_request(:put, endpoint + path) end def project_path File.expand_path("../..", __FILE__) end def fixture_path File.expand_path("../fixtures", __FILE__) end def fixture(file) File.new(fixture_path + '/' + file) end def status_from_fixture(file) Twitter::Status.new(MultiJson.load(fixture(file).read, :symbolize_keys => true)) end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
t-1.7.2 | spec/helper.rb |