Sha256: 45e6388871f4836e9635d6e5bdc2c5b5e5969ebd011fb0e548d701a3a6baa4de
Contents?: true
Size: 723 Bytes
Versions: 4
Compression:
Stored size: 723 Bytes
Contents
$LOAD_PATH.unshift(File.dirname(__FILE__)) $LOAD_PATH.unshift(File.join(File.dirname(__FILE__), '..', 'lib')) begin require 'bundler' rescue LoadError require 'rubygems' require 'bundler' end Bundler.setup require 'grendel' require 'spec' require 'spec/autorun' require 'webmock/rspec' include WebMock Spec::Runner.configure do |config| WebMock.disable_net_connect! # helper to add Content-Type: application/json to each request def stub_json_request(method, uri, body, headers = {}) headers = headers.merge("Content-Type" => "application/json") status = headers.delete(:status) || 200 stub_request(method, uri). to_return(:body => body, :status => status, :headers => headers) end end
Version data entries
4 entries across 4 versions & 1 rubygems
Version | Path |
---|---|
grendel-ruby-0.1.5 | spec/spec_helper.rb |
grendel-ruby-0.1.4 | spec/spec_helper.rb |
grendel-ruby-0.1.3 | spec/spec_helper.rb |
grendel-ruby-0.1.2 | spec/spec_helper.rb |