dubdubdub 0.0.1 → 0.1.0

Sign up to get free protection for your applications and to get access to all the features.
data/Gemfile CHANGED
@@ -1,5 +1,7 @@
1
1
  source "http://rubygems.org"
2
2
 
3
+ gem 'rest-client'
4
+
3
5
  # Add dependencies to develop your gem here.
4
6
  # Include everything needed to run rake, tests, features, etc.
5
7
  group :development do
data/Gemfile.lock CHANGED
@@ -12,6 +12,7 @@ GEM
12
12
  rdoc
13
13
  json (1.7.5)
14
14
  method_source (0.8.1)
15
+ mime-types (1.19)
15
16
  pry (0.9.10)
16
17
  coderay (~> 1.0.5)
17
18
  method_source (~> 0.8)
@@ -19,6 +20,8 @@ GEM
19
20
  rake (10.0.2)
20
21
  rdoc (3.12)
21
22
  json (~> 1.4)
23
+ rest-client (1.6.7)
24
+ mime-types (>= 1.16)
22
25
  rspec (2.8.0)
23
26
  rspec-core (~> 2.8.0)
24
27
  rspec-expectations (~> 2.8.0)
@@ -38,5 +41,6 @@ DEPENDENCIES
38
41
  fakeweb (~> 1.3.0)
39
42
  jeweler (~> 1.8.4)
40
43
  pry
44
+ rest-client
41
45
  rspec (~> 2.8.0)
42
46
  vcr (~> 2.3.0)
data/dubdubdub.gemspec CHANGED
@@ -5,7 +5,7 @@
5
5
 
6
6
  Gem::Specification.new do |s|
7
7
  s.name = "dubdubdub"
8
- s.version = "0.0.1"
8
+ s.version = "0.1.0"
9
9
 
10
10
  s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
11
11
  s.authors = ["James Hu"]
@@ -39,7 +39,10 @@ Gem::Specification.new do |s|
39
39
  "spec/vcr/follow_url/pass_block_iteration.yml",
40
40
  "spec/vcr/follow_url/proxied.yml",
41
41
  "spec/vcr/follow_url/proxy.yml",
42
- "spec/vcr/follow_url/proxy_forbidden.yml"
42
+ "spec/vcr/follow_url/proxy_forbidden.yml",
43
+ "spec/vcr/get/basic.yml",
44
+ "spec/vcr/get/params.yml",
45
+ "spec/vcr/get/proxy.yml"
43
46
  ]
44
47
  s.homepage = "http://github.com/axsuul/dubdubdub"
45
48
  s.licenses = ["MIT"]
@@ -51,6 +54,7 @@ Gem::Specification.new do |s|
51
54
  s.specification_version = 3
52
55
 
53
56
  if Gem::Version.new(Gem::VERSION) >= Gem::Version.new('1.2.0') then
57
+ s.add_runtime_dependency(%q<rest-client>, [">= 0"])
54
58
  s.add_development_dependency(%q<rspec>, ["~> 2.8.0"])
55
59
  s.add_development_dependency(%q<vcr>, ["~> 2.3.0"])
56
60
  s.add_development_dependency(%q<fakeweb>, ["~> 1.3.0"])
@@ -58,6 +62,7 @@ Gem::Specification.new do |s|
58
62
  s.add_development_dependency(%q<jeweler>, ["~> 1.8.4"])
59
63
  s.add_development_dependency(%q<pry>, [">= 0"])
60
64
  else
65
+ s.add_dependency(%q<rest-client>, [">= 0"])
61
66
  s.add_dependency(%q<rspec>, ["~> 2.8.0"])
62
67
  s.add_dependency(%q<vcr>, ["~> 2.3.0"])
63
68
  s.add_dependency(%q<fakeweb>, ["~> 1.3.0"])
@@ -66,6 +71,7 @@ Gem::Specification.new do |s|
66
71
  s.add_dependency(%q<pry>, [">= 0"])
67
72
  end
68
73
  else
74
+ s.add_dependency(%q<rest-client>, [">= 0"])
69
75
  s.add_dependency(%q<rspec>, ["~> 2.8.0"])
70
76
  s.add_dependency(%q<vcr>, ["~> 2.3.0"])
71
77
  s.add_dependency(%q<fakeweb>, ["~> 1.3.0"])
data/lib/dubdubdub.rb CHANGED
@@ -1,6 +1,6 @@
1
1
  class DubDubDub
2
2
  # Version
3
- VERSION = "0.0.1"
3
+ VERSION = "0.1.0"
4
4
 
5
5
  attr_accessor :client
6
6
 
@@ -13,7 +13,7 @@ class DubDubDub
13
13
  if @client.respond_to?(method)
14
14
  @client.send(method, *args, &block)
15
15
  else
16
- send(method, *args, &block)
16
+ super
17
17
  end
18
18
  end
19
19
  end
@@ -45,6 +45,29 @@ class DubDubDub::Client
45
45
  http
46
46
  end
47
47
 
48
+ # Returns a RestClient::Resource
49
+ def rest_client_resource(url)
50
+ options = {}
51
+ options[:proxy] = proxy if proxy?
52
+
53
+ RestClient::Resource.new(url, options)
54
+ end
55
+
56
+ # Perform a GET request
57
+ def get(url, *args)
58
+ rest_client_resource(url).get(*args)
59
+ end
60
+
61
+ # Perform a POST request
62
+ def post(url, *args)
63
+ rest_client_resource(url).post(*args)
64
+ end
65
+
66
+ # Perform a DELETE request
67
+ def delete(url, *args)
68
+ rest_client_resource(url).delete(*args)
69
+ end
70
+
48
71
  # Follow a url to the end until it can no longer go any further
49
72
  # Even if it times out, it will return the url that it times out on!
50
73
  def follow_url(url, options = {}, &block)
@@ -1,6 +1,7 @@
1
1
  # encoding: utf-8
2
2
 
3
3
  require File.expand_path(File.dirname(__FILE__) + '/spec_helper')
4
+ require 'rest-client'
4
5
 
5
6
  describe DubDubDub do
6
7
  let(:www) { DubDubDub.new }
@@ -27,6 +28,11 @@ describe DubDubDub do
27
28
  www.proxy_host.should == "203.131.212.166"
28
29
  www.proxy_port.should == 80
29
30
  end
31
+
32
+ it "does not pass the method to client if that method doesn't exist within the client" do
33
+ www = DubDubDub.new
34
+ lambda { www.some_method_that_doesnt_exist }.should raise_error(NameError)
35
+ end
30
36
  end
31
37
 
32
38
  describe '#client' do
@@ -35,6 +41,23 @@ describe DubDubDub do
35
41
  end
36
42
  end
37
43
 
44
+ describe '#get' do
45
+ it "makes a GET request using RestClient and returns a response", vcr: { cassette_name: "get/basic", record: :once } do
46
+ response = www.get "http://www.google.com"
47
+ response.should be_a RestClient::Response
48
+ end
49
+
50
+ it "works with params", vcr: { cassette_name: "get/params", record: :once } do
51
+ response = www.get "http://www.google.com", params: { foo: "bar" }
52
+ response.should be_a RestClient::Response
53
+ end
54
+
55
+ it "works with a proxy", vcr: { cassette_name: "get/proxy", record: :once } do
56
+ www.proxy = "203.131.212.166"
57
+ response = www.get "http://www.google.com"
58
+ end
59
+ end
60
+
38
61
  describe '#follow_url' do
39
62
  it "follows url to the end", vcr: { cassette_name: "follow_url/base", record: :once } do
40
63
  www.follow_url("http://say.ly/TCc1CEp").should == "http://www.whosay.com/TomHanks/photos/148406"
@@ -0,0 +1,169 @@
1
+ ---
2
+ http_interactions:
3
+ - request:
4
+ method: get
5
+ uri: http://www.google.com/
6
+ body:
7
+ encoding: US-ASCII
8
+ string: ''
9
+ headers:
10
+ accept:
11
+ - ! '*/*; q=0.5, application/xml'
12
+ accept-encoding:
13
+ - gzip, deflate
14
+ user-agent:
15
+ - Ruby
16
+ response:
17
+ status:
18
+ code: 200
19
+ message: OK
20
+ headers:
21
+ date:
22
+ - Mon, 03 Dec 2012 22:03:57 GMT
23
+ expires:
24
+ - '-1'
25
+ cache-control:
26
+ - private, max-age=0
27
+ content-type:
28
+ - text/html; charset=ISO-8859-1
29
+ set-cookie:
30
+ - PREF=ID=10344d794896853a:FF=0:TM=1354572237:LM=1354572237:S=NJoQP4jOSKmZnuMw;
31
+ expires=Wed, 03-Dec-2014 22:03:57 GMT; path=/; domain=.google.com
32
+ - NID=66=ewIco5oxoApok2zN-eHX_S2_-X389fhHSNL5X1X6bOCZL7DACugAiHXTkThvTU_Hr8c2ErRvWBvdMj1fuVzLj14N87NZgVG6Mxt43-ER_4Hhij_1vOV4Tt3H8sjkcfSO;
33
+ expires=Tue, 04-Jun-2013 22:03:57 GMT; path=/; domain=.google.com; HttpOnly
34
+ p3p:
35
+ - CP="This is not a P3P policy! See http://www.google.com/support/accounts/bin/answer.py?hl=en&answer=151657
36
+ for more info."
37
+ server:
38
+ - gws
39
+ x-xss-protection:
40
+ - 1; mode=block
41
+ x-frame-options:
42
+ - SAMEORIGIN
43
+ transfer-encoding:
44
+ - chunked
45
+ body:
46
+ encoding: US-ASCII
47
+ string: ! '<!doctype html><html itemscope="itemscope" itemtype="http://schema.org/WebPage"><head><meta
48
+ content="Search the world''s information, including webpages, images, videos
49
+ and more. Google has many special features to help you find exactly what you''re
50
+ looking for." name="description"><meta content="noodp" name="robots"><meta
51
+ itemprop="image" content="/images/google_favicon_128.png"><title>Google</title><script>(function(){
52
+
53
+ window.google={kEI:"zSG9UNT6HKKYiQL11oDoBA",getEI:function(a){for(var b;a&&(!a.getAttribute||!(b=a.getAttribute("eid")));)a=a.parentNode;return
54
+ b||google.kEI},https:function(){return"https:"==window.location.protocol},kEXPI:"17259,39523,39978,40363,4000116,4000472,4000566,4000945,4000955,4001372,4001456,4001569,4001855,4001933,4001966,4002000,4002036,4002048,4002161,4002240,4002274,4002348,4002359,4002391,4002436,4002460,4002466,4002484,4002510,4002562,4002710,4002733,4002743,4002769,4002771,4002789",kCSI:{e:"17259,39523,39978,40363,4000116,4000472,4000566,4000945,4000955,4001372,4001456,4001569,4001855,4001933,4001966,4002000,4002036,4002048,4002161,4002240,4002274,4002348,4002359,4002391,4002436,4002460,4002466,4002484,4002510,4002562,4002710,4002733,4002743,4002769,4002771,4002789",ei:"zSG9UNT6HKKYiQL11oDoBA"},authuser:0,ml:function(){},kHL:"en",time:function(){return(new
55
+ Date).getTime()},log:function(a,
56
+
57
+ b,c,j){var d=new Image,f=google.lc,e=google.li,g="";d.onerror=d.onload=d.onabort=function(){delete
58
+ f[e]};f[e]=d;!c&&-1==b.search("&ei=")&&(g="&ei="+google.getEI(j));c=c||"/gen_204?atyp=i&ct="+a+"&cad="+b+g+"&zx="+google.time();a=/^http:/i;a.test(c)&&google.https()?(google.ml(Error("GLMM"),!1,{src:c}),delete
59
+ f[e]):(d.src=c,google.li=e+1)},lc:[],li:0,Toolbelt:{},y:{},x:function(a,b){google.y[a.id]=[a,b];return!1}};})();
60
+
61
+ window.google.sn="webhp";window.google.timers={};window.google.startTick=function(a,b){window.google.timers[a]={t:{start:(new
62
+ Date).getTime()},bfr:!(!b)}};window.google.tick=function(a,b,c){if(!window.google.timers[a])google.startTick(a);window.google.timers[a].t[b]=c||(new
63
+ Date).getTime()};google.startTick("load",true);try{}catch(u){}
64
+
65
+ var _gjwl=location;function _gjuc(){var a=_gjwl.href.indexOf("#");if(0<=a&&(a=_gjwl.href.substring(a),0<a.indexOf("&q=")||0<=a.indexOf("#q=")))if(a=a.substring(1),-1==a.indexOf("#")){for(var
66
+ d=0;d<a.length;){var b=d;"&"==a.charAt(b)&&++b;var c=a.indexOf("&",b);-1==c&&(c=a.length);b=a.substring(b,c);if(0==b.indexOf("fp="))a=a.substring(0,d)+a.substring(c,a.length),c=d;else
67
+ if("cad=h"==b)return 0;d=c}_gjwl.href="/search?"+a+"&cad=h";return 1}return
68
+ 0}
69
+
70
+ function _gjp(){(!window._gjwl.hash||!window._gjuc())&&setTimeout(_gjp,500)};
71
+
72
+ window._gjp&&_gjp();</script><style>#gbar,#guser{font-size:13px;padding-top:1px
73
+ !important;}#gbar{height:22px}#guser{padding-bottom:7px !important;text-align:right}.gbh,.gbd{border-top:1px
74
+ solid #c9d7f1;font-size:1px}.gbh{height:0;position:absolute;top:24px;width:100%}@media
75
+ all{.gb1{height:22;margin-right:.5em;vertical-align:top}#gbar{float:left}}a.gb1,a.gb4{text-decoration:underline
76
+ !important}a.gb1,a.gb4{color:#00c !important}.gbi .gb4{color:#dd8e27 !important}.gbf
77
+ .gb4{color:#900 !important}</style><style id="gstyle">body{margin:0;overflow-y:scroll}#gog{padding:3px
78
+ 8px 0}td{line-height:.8em}.gac_m td{line-height:17px}form{margin-bottom:20px}body,td,a,p,.h{font-family:arial,sans-serif}.h{color:#36c;font-size:20px}.q{color:#00c}.ts
79
+ td{padding:0}.ts{border-collapse:collapse}em{font-weight:bold;font-style:normal}.lst{height:25px;width:496px}.gsfi,.lst{font:18px
80
+ arial,sans-serif}.gsfs{font:17px arial,sans-serif}.ds{display:-moz-inline-box;display:inline-block;margin:3px
81
+ 0 4px;margin-left:4px}input{font-family:inherit}a.gb1,a.gb2,a.gb3,a.gb4{color:#11c
82
+ !important}body{background:#fff;color:black}a{color:#11c;text-decoration:none}a:hover,a:active{text-decoration:underline}.fl
83
+ a{color:#36c}a:visited{color:#551a8b}a.gb1,a.gb4{text-decoration:underline}a.gb3:hover{text-decoration:none}#ghead
84
+ a.gb2:hover{color:#fff!important}.sblc{padding-top:5px}.sblc a{display:block;margin:2px
85
+ 0;margin-left:13px;font-size:11px;}.lsbb{background:#eee;border:solid 1px;border-color:#ccc
86
+ #999 #999 #ccc;height:30px;display:block}.ftl,#fll a{display:inline-block;margin:0
87
+ 12px}.lsb{background:url(/images/srpr/nav_logo80.png) 0 -258px repeat-x;border:none;color:#000;cursor:pointer;height:30px;margin:0;outline:0;font:15px
88
+ arial,sans-serif;vertical-align:top}.lsb:active{background:#ccc}.lst:focus{outline:none}#addlang
89
+ a{padding:0 3px}.gac_v div{display:none}.gac_v .gac_v2,.gac_bt{display:block!important}table.gssb_c{z-index:986 }.nbcl{background:url(/images/srpr/nav_logo80.png)
90
+ no-repeat ;height:px;width:px}</style><script></script> </head><body dir="ltr"
91
+ bgcolor="#fff"><script>(function(){var src=''/images/srpr/nav_logo80.png'';var
92
+ iesg=false;document.body.onload = function(){window.n && window.n();if (document.images){new
93
+ Image().src=src;}
94
+
95
+ if (!iesg){document.f&&document.f.q.focus();document.gbqf&&document.gbqf.q.focus();}
96
+
97
+ }
98
+
99
+ })();</script><textarea id="csi" style="display:none"></textarea><div id="mngb"><div
100
+ id=gbar><nobr><b class=gb1>Search</b> <a class=gb1 href="http://www.google.com/imghp?hl=en&tab=wi">Images</a>
101
+ <a class=gb1 href="http://maps.google.com/maps?hl=en&tab=wl">Maps</a> <a class=gb1
102
+ href="https://play.google.com/?hl=en&tab=w8">Play</a> <a class=gb1 href="http://www.youtube.com/?tab=wy">YouTube</a>
103
+ <a class=gb1 href="http://news.google.com/nwshp?hl=en&tab=wn">News</a> <a
104
+ class=gb1 href="https://mail.google.com/mail/?tab=wm">Gmail</a> <a class=gb1
105
+ href="https://drive.google.com/?tab=wo">Drive</a> <a class=gb1 style="text-decoration:none"
106
+ href="http://www.google.com/intl/en/options/"><u>More</u> &raquo;</a></nobr></div><div
107
+ id=guser width=100%><nobr><span id=gbn class=gbi></span><span id=gbf class=gbf></span><span
108
+ id=gbe></span><a href="http://www.google.com/history/optout?hl=en" class=gb4>Web
109
+ History</a> | <a href="/preferences?hl=en" class=gb4>Settings</a> | <a target=_top
110
+ id=gb_70 href="https://accounts.google.com/ServiceLogin?hl=en&continue=http://www.google.com/"
111
+ class=gb4>Sign in</a></nobr></div><div class=gbh style=left:0></div><div class=gbh
112
+ style=right:0></div></div><iframe name="wgjf" style="display:none"></iframe><center><br
113
+ clear="all" id="lgpd"><div id="lga"><img alt="Google" height="95" src="/intl/en_ALL/images/srpr/logo1w.png"
114
+ width="275" id="hplogo" onload="window.lol&&lol()" style="padding:28px 0 14px"><br><br></div><form
115
+ action="/search" name="f"><table cellpadding="0" cellspacing="0"><tr valign="top"><td
116
+ width="25%">&nbsp;</td><td align="center" nowrap="nowrap"><input name="ie"
117
+ value="ISO-8859-1" type="hidden"><input value="en" name="hl" type="hidden"><input
118
+ name="source" type="hidden" value="hp"><div class="ds" style="height:32px;margin:4px
119
+ 0"><input autocomplete="off" class="lst" value="" title="Google Search" maxlength="2048"
120
+ name="q" size="57" style="color:#000;margin:0;padding:5px 8px 0 6px;vertical-align:top"></div><br
121
+ style="line-height:0"><span class="ds"><span class="lsbb"><input class="lsb"
122
+ value="Google Search" name="btnG" type="submit"></span></span><span class="ds"><span
123
+ class="lsbb"><input class="lsb" value="I''m Feeling Lucky" name="btnI" type="submit"
124
+ onclick="if(this.form.q.value)this.checked=1; else top.location=''/doodles/''"></span></span></td><td
125
+ class="fl sblc" align="left" nowrap="nowrap" width="25%"><a href="/advanced_search?hl=en&amp;authuser=0">Advanced
126
+ search</a><a href="/language_tools?hl=en&amp;authuser=0">Language tools</a></td></tr></table><input
127
+ type="hidden" id="gbv" name="gbv" value="1"></form><div id="gac_scont"></div><div
128
+ style="font-size:83%;min-height:3.5em"><br><div id="prm"><font id="hpplink"
129
+ size="-1" style="behavior:url(#default#userdata)"><span style="color:red"></span>Love
130
+ the free and open Internet? <a href="https://www.google.com/takeaction/?utm_source=google&amp;utm_medium=hpp&amp;utm_campaign=12032012freeandopen_en"
131
+ onclick="google.promos&&google.promos.link&& google.promos.link.cl()">Tell
132
+ the world''s governments</a> to keep it that way.</font><br><br><br><script
133
+ type="text/javascript">(function(){var d={promos:{}};d.promos.localStorage={};d.promos.localStorage.isLocalstorageSupported=function(){try{return"object"==typeof
134
+ window.localStorage}catch(a){return!1}};d.promos.localStorage.getPersistData=function(a){a=window.localStorage.getItem(a);return!a?"":a.toString()};d.promos.localStorage.setPersistData=function(a,b){window.localStorage.setItem(a,b)};d.promos.localStorage.removePersistData=function(a){window.localStorage.removeItem(a)};google.promos||(google.promos={});google.promos.ActionType={ACCEPT:"a",CANCEL:"c",DISMISS:"d",CLICK:"h",IMPRESSION:"i",NO_THANKS:"n",X_BUTTON:"x",MGMHP_ACCEPT:"ma",MGMHP_CANCEL:"mc",MGMHP_IMPRESSION:"mi",MGMHPPD_ACCEPT:"pa",MGMHPPD_CANCEL:"pc",MGMHPPD_IMPRESSION:"pi",MGMHPPD_NO_THANKS:"pn",MGMHPPD_NO_BUTTON:"px",MGMHPPD_DISMISS:"pd",PUSHDOWN_ACCEPT:"gpa",PUSHDOWN_IMPRESSION:"gpi",PUSHDOWN_NO_THANKS:"gpn",PUSHDOWN_NO_BUTTON:"gpx",PUSHDOWN_DISMISS:"gpd"};google.promos.sl=function(a,b,c,e){a=[c,"id="+a,"loc="+google.sn];a.push("oi=promoslinger");e&&a.push(e);google.log(b,a.join("&"))};google.promos.si=function(a,b,c,e){0.01>Math.random()&&google.promos.sl(a,b,e?e:google.promos.ActionType.IMPRESSION,c)};google.promos.spd=function(a,b,c){if(d.promos.localStorage.isLocalstorageSupported())d.promos.localStorage.setPersistData(b,c);else
135
+ if(a)try{a.setAttribute(b,c),a.save(a.id)}catch(e){google.ml(e,!1,{cause:"PERSIST_DATA_FAIL"})}};google.promos.gpd=function(a,b){if(d.promos.localStorage.isLocalstorageSupported())return
136
+ d.promos.localStorage.getPersistData(b);if(a)try{return a.load(a.id),a.getAttribute(b)}catch(c){google.ml(c,!1,{cause:"PERSIST_DATA_FAIL"})}return""};google.promos.rpd=function(a,b){if(d.promos.localStorage.isLocalstorageSupported())d.promos.localStorage.removePersistData(b);else
137
+ if(a)try{a.load(a.id),a.removeAttribute(b),a.save(a.id)}catch(c){google.ml(c,!1,{cause:"PERSIST_DATA_FAIL"})}};google.promos.aeh=function(a,b,c){a.addEventListener?a.addEventListener(b,c,!1):a.attachEvent&&a.attachEvent("on"+b,c)};})();</script><script
138
+ type="text/javascript">(function(){var c,e,g=0,h;google.promos.link||(google.promos.link={});google.promos.link.getExtraLogData_=function(b){var
139
+ a=document.getElementById(h);if(a){var f=e+"_upccb",d=parseInt(google.promos.gpd(a,f)||0,10);d++;g++;google.promos.spd(a,f,d);a=[["upcc",g].join("="),["upccb",d].join("=")];b&&a.push(b);return
140
+ a.join("&")}};google.promos.link.cl=function(b){try{google.promos.sl(e,c,google.promos.ActionType.CLICK,google.promos.link.getExtraLogData_(b))}catch(a){google.ml(a,!1,{cause:c+"_CL"})}};google.promos.link.init=function(b,a,f){try{e=b,c=a,h=f,google.promos.si(e,c)}catch(d){google.ml(d,!1,{cause:c+"_INIT"})}};})();</script><script>(function(){var
141
+ sourceWebappPromoID=1579001;var payloadType=3;google.promos.link.init(sourceWebappPromoID,payloadType,''hpplink'');})();</script></div></div><span
142
+ id="footer"><div style="font-size:10pt"><div id="fll" style="margin:19px auto;text-align:center"><a
143
+ href="/intl/en/ads/">Advertising&nbsp;Programs</a><a href="/services/">Business
144
+ Solutions</a><a href="https://plus.google.com/116899029375914044550" rel="publisher">+Google</a><a
145
+ href="/intl/en/about.html">About Google</a></div></div><p style="color:#767676;font-size:8pt">&copy;
146
+ 2012 - <a href="/intl/en/policies/">Privacy & Terms</a></p></span></center><div
147
+ id=xjsd></div><div id=xjsi><script>if(google.y)google.y.first=[];(function(){var
148
+ b;function c(a){window.setTimeout(function(){var d=document.createElement("script");d.src=a;document.getElementById("xjsd").appendChild(d)},0)}google.dljp=function(a){b=a;google.xjsi||(google.xjsu=a,c(b))};google.dlj=c;})();
149
+
150
+ if(!google.xjs){google.dstr=[];google.rein=[];window._=window._||{};window._._DumpException=function(e){throw
151
+ e};if(google.timers&&google.timers.load.t){google.timers.load.t.xjsls=new
152
+ Date().getTime();}google.dljp(''/xjs/_/js/hp/sb_he,pcc/rt\x3dj/ver\x3dekMxmVjFIzI.en_US./d\x3d1/sv\x3d1/rs\x3dAItRSTM0lksRtI2VxMWJM1mGGSAc7V2OnQ'');google.xjs=1;}google.pmc={sb:{"agen":false,"cgen":true,"client":"heirloom-hp","dh":true,"ds":"","eqch":true,"fl":true,"host":"google.com","jsonp":true,"msgs":{"lcky":"I\u0026#39;m
153
+ Feeling Lucky","lml":"Learn more","oskt":"Input tools","psrc":"This search
154
+ was removed from your \u003Ca href=\"/history\"\u003EWeb History\u003C/a\u003E","psrl":"Remove","sbit":"Search
155
+ by image","srch":"Google Search"},"ovr":{"l":1,"ms":1},"pq":"","qcpw":false,"scd":10,"sce":5,"stok":"XiSEhY3Wy8NP0yq7qMI_SslvMHg"},pcc:{}};google.y.first.push(function(){if(google.med){google.med(''init'');google.initHistory();google.med(''history'');}google.History&&google.History.initialize(''/'');google.hs&&google.hs.init&&google.hs.init()});if(google.j&&google.j.en&&google.j.xi){window.setTimeout(google.j.xi,0);}</script></div><script>(function(){var
156
+ b,c,d,e;function g(a,f){a.removeEventListener?(a.removeEventListener("load",f,!1),a.removeEventListener("error",f,!1)):(a.detachEvent("onload",f),a.detachEvent("onerror",f))}function
157
+ h(a){e=(new Date).getTime();++c;a=a||window.event;a=a.target||a.srcElement;g(a,h)}var
158
+ j=document.getElementsByTagName("img");b=j.length;
159
+
160
+ for(var k=c=0,l;k<b;++k)l=j[k],l.complete||"string"!=typeof l.src||!l.src?++c:l.addEventListener?(l.addEventListener("load",h,!1),l.addEventListener("error",h,!1)):(l.attachEvent("onload",h),l.attachEvent("onerror",h));d=b-c;
161
+
162
+ function m(){if(google.timers.load.t){google.timers.load.t.ol=(new Date).getTime();google.timers.load.t.iml=e;google.kCSI.imc=c;google.kCSI.imn=b;google.kCSI.imp=d;void
163
+ 0!==google.stt&&(google.kCSI.stt=google.stt);google.csiReport&&google.csiReport()}}window.addEventListener?window.addEventListener("load",m,!1):window.attachEvent&&window.attachEvent("onload",m);google.timers.load.t.prt=e=(new
164
+ Date).getTime();})();
165
+
166
+ </script></body></html>'
167
+ http_version: '1.1'
168
+ recorded_at: Mon, 03 Dec 2012 22:03:57 GMT
169
+ recorded_with: VCR 2.3.0
@@ -0,0 +1,169 @@
1
+ ---
2
+ http_interactions:
3
+ - request:
4
+ method: get
5
+ uri: http://www.google.com/?foo=bar
6
+ body:
7
+ encoding: US-ASCII
8
+ string: ''
9
+ headers:
10
+ accept:
11
+ - ! '*/*; q=0.5, application/xml'
12
+ accept-encoding:
13
+ - gzip, deflate
14
+ user-agent:
15
+ - Ruby
16
+ response:
17
+ status:
18
+ code: 200
19
+ message: OK
20
+ headers:
21
+ date:
22
+ - Mon, 03 Dec 2012 22:11:13 GMT
23
+ expires:
24
+ - '-1'
25
+ cache-control:
26
+ - private, max-age=0
27
+ content-type:
28
+ - text/html; charset=ISO-8859-1
29
+ set-cookie:
30
+ - PREF=ID=44365a96fa0bf536:FF=0:TM=1354572673:LM=1354572673:S=QCEHE-3YAMUnMfOr;
31
+ expires=Wed, 03-Dec-2014 22:11:13 GMT; path=/; domain=.google.com
32
+ - NID=66=AKkzqExD4wH48VQdhDZA3eaVLUqVcoj48GvdXIdjvmijnyCDJdfeb834xuE0HtFOfXufsyuNJGokQtR8z8fV68aeZTMjrw6UMMLdJGuu24tpydRms7w6nssN8hfOi0Rx;
33
+ expires=Tue, 04-Jun-2013 22:11:13 GMT; path=/; domain=.google.com; HttpOnly
34
+ p3p:
35
+ - CP="This is not a P3P policy! See http://www.google.com/support/accounts/bin/answer.py?hl=en&answer=151657
36
+ for more info."
37
+ server:
38
+ - gws
39
+ x-xss-protection:
40
+ - 1; mode=block
41
+ x-frame-options:
42
+ - SAMEORIGIN
43
+ transfer-encoding:
44
+ - chunked
45
+ body:
46
+ encoding: US-ASCII
47
+ string: ! '<!doctype html><html itemscope="itemscope" itemtype="http://schema.org/WebPage"><head><meta
48
+ content="Search the world''s information, including webpages, images, videos
49
+ and more. Google has many special features to help you find exactly what you''re
50
+ looking for." name="description"><meta content="noodp" name="robots"><meta
51
+ itemprop="image" content="/images/google_favicon_128.png"><title>Google</title><script>(function(){
52
+
53
+ window.google={kEI:"gSO9UO7kG8rciQKQ3IDQCQ",getEI:function(a){for(var b;a&&(!a.getAttribute||!(b=a.getAttribute("eid")));)a=a.parentNode;return
54
+ b||google.kEI},https:function(){return"https:"==window.location.protocol},kEXPI:"17259,24472,35702,39523,39977,40363,4000116,4000472,4000567,4000604,4000945,4000955,4001372,4001456,4001569,4001855,4001933,4001959,4001966,4002000,4002036,4002155,4002161,4002234,4002240,4002274,4002348,4002359,4002391,4002436,4002460,4002466,4002510,4002562,4002710,4002734,4002744,4002771,4002789",kCSI:{e:"17259,24472,35702,39523,39977,40363,4000116,4000472,4000567,4000604,4000945,4000955,4001372,4001456,4001569,4001855,4001933,4001959,4001966,4002000,4002036,4002155,4002161,4002234,4002240,4002274,4002348,4002359,4002391,4002436,4002460,4002466,4002510,4002562,4002710,4002734,4002744,4002771,4002789",ei:"gSO9UO7kG8rciQKQ3IDQCQ"},authuser:0,ml:function(){},kHL:"en",time:function(){return(new
55
+ Date).getTime()},log:function(a,
56
+
57
+ b,c,j){var d=new Image,f=google.lc,e=google.li,g="";d.onerror=d.onload=d.onabort=function(){delete
58
+ f[e]};f[e]=d;!c&&-1==b.search("&ei=")&&(g="&ei="+google.getEI(j));c=c||"/gen_204?atyp=i&ct="+a+"&cad="+b+g+"&zx="+google.time();a=/^http:/i;a.test(c)&&google.https()?(google.ml(Error("GLMM"),!1,{src:c}),delete
59
+ f[e]):(d.src=c,google.li=e+1)},lc:[],li:0,Toolbelt:{},y:{},x:function(a,b){google.y[a.id]=[a,b];return!1}};})();
60
+
61
+ window.google.sn="webhp";window.google.timers={};window.google.startTick=function(a,b){window.google.timers[a]={t:{start:(new
62
+ Date).getTime()},bfr:!(!b)}};window.google.tick=function(a,b,c){if(!window.google.timers[a])google.startTick(a);window.google.timers[a].t[b]=c||(new
63
+ Date).getTime()};google.startTick("load",true);try{}catch(u){}
64
+
65
+ var _gjwl=location;function _gjuc(){var a=_gjwl.href.indexOf("#");if(0<=a&&(a=_gjwl.href.substring(a),0<a.indexOf("&q=")||0<=a.indexOf("#q=")))if(a=a.substring(1),-1==a.indexOf("#")){for(var
66
+ d=0;d<a.length;){var b=d;"&"==a.charAt(b)&&++b;var c=a.indexOf("&",b);-1==c&&(c=a.length);b=a.substring(b,c);if(0==b.indexOf("fp="))a=a.substring(0,d)+a.substring(c,a.length),c=d;else
67
+ if("cad=h"==b)return 0;d=c}_gjwl.href="/search?"+a+"&cad=h";return 1}return
68
+ 0}
69
+
70
+ function _gjp(){(!window._gjwl.hash||!window._gjuc())&&setTimeout(_gjp,500)};
71
+
72
+ window._gjp&&_gjp();</script><style>#gbar,#guser{font-size:13px;padding-top:1px
73
+ !important;}#gbar{height:22px}#guser{padding-bottom:7px !important;text-align:right}.gbh,.gbd{border-top:1px
74
+ solid #c9d7f1;font-size:1px}.gbh{height:0;position:absolute;top:24px;width:100%}@media
75
+ all{.gb1{height:22;margin-right:.5em;vertical-align:top}#gbar{float:left}}a.gb1,a.gb4{text-decoration:underline
76
+ !important}a.gb1,a.gb4{color:#00c !important}.gbi .gb4{color:#dd8e27 !important}.gbf
77
+ .gb4{color:#900 !important}</style><style id="gstyle">body{margin:0;overflow-y:scroll}#gog{padding:3px
78
+ 8px 0}td{line-height:.8em}.gac_m td{line-height:17px}form{margin-bottom:20px}body,td,a,p,.h{font-family:arial,sans-serif}.h{color:#36c;font-size:20px}.q{color:#00c}.ts
79
+ td{padding:0}.ts{border-collapse:collapse}em{font-weight:bold;font-style:normal}.lst{height:25px;width:496px}.gsfi,.lst{font:18px
80
+ arial,sans-serif}.gsfs{font:17px arial,sans-serif}.ds{display:-moz-inline-box;display:inline-block;margin:3px
81
+ 0 4px;margin-left:4px}input{font-family:inherit}a.gb1,a.gb2,a.gb3,a.gb4{color:#11c
82
+ !important}body{background:#fff;color:black}a{color:#11c;text-decoration:none}a:hover,a:active{text-decoration:underline}.fl
83
+ a{color:#36c}a:visited{color:#551a8b}a.gb1,a.gb4{text-decoration:underline}a.gb3:hover{text-decoration:none}#ghead
84
+ a.gb2:hover{color:#fff!important}.sblc{padding-top:5px}.sblc a{display:block;margin:2px
85
+ 0;margin-left:13px;font-size:11px;}.lsbb{background:#eee;border:solid 1px;border-color:#ccc
86
+ #999 #999 #ccc;height:30px;display:block}.ftl,#fll a{display:inline-block;margin:0
87
+ 12px}.lsb{background:url(/images/srpr/nav_logo80.png) 0 -258px repeat-x;border:none;color:#000;cursor:pointer;height:30px;margin:0;outline:0;font:15px
88
+ arial,sans-serif;vertical-align:top}.lsb:active{background:#ccc}.lst:focus{outline:none}#addlang
89
+ a{padding:0 3px}.gac_v div{display:none}.gac_v .gac_v2,.gac_bt{display:block!important}table.gssb_c{z-index:986 }.nbcl{background:url(/images/srpr/nav_logo80.png)
90
+ no-repeat ;height:px;width:px}</style><script></script> </head><body dir="ltr"
91
+ bgcolor="#fff"><script>(function(){var src=''/images/srpr/nav_logo80.png'';var
92
+ iesg=false;document.body.onload = function(){window.n && window.n();if (document.images){new
93
+ Image().src=src;}
94
+
95
+ if (!iesg){document.f&&document.f.q.focus();document.gbqf&&document.gbqf.q.focus();}
96
+
97
+ }
98
+
99
+ })();</script><textarea id="csi" style="display:none"></textarea><div id="mngb"><div
100
+ id=gbar><nobr><b class=gb1>Search</b> <a class=gb1 href="http://www.google.com/imghp?hl=en&tab=wi">Images</a>
101
+ <a class=gb1 href="http://maps.google.com/maps?hl=en&tab=wl">Maps</a> <a class=gb1
102
+ href="https://play.google.com/?hl=en&tab=w8">Play</a> <a class=gb1 href="http://www.youtube.com/?tab=wy">YouTube</a>
103
+ <a class=gb1 href="http://news.google.com/nwshp?hl=en&tab=wn">News</a> <a
104
+ class=gb1 href="https://mail.google.com/mail/?tab=wm">Gmail</a> <a class=gb1
105
+ href="https://drive.google.com/?tab=wo">Drive</a> <a class=gb1 style="text-decoration:none"
106
+ href="http://www.google.com/intl/en/options/"><u>More</u> &raquo;</a></nobr></div><div
107
+ id=guser width=100%><nobr><span id=gbn class=gbi></span><span id=gbf class=gbf></span><span
108
+ id=gbe></span><a href="http://www.google.com/history/optout?hl=en" class=gb4>Web
109
+ History</a> | <a href="/preferences?hl=en" class=gb4>Settings</a> | <a target=_top
110
+ id=gb_70 href="https://accounts.google.com/ServiceLogin?hl=en&continue=http://www.google.com/%3Ffoo%3Dbar"
111
+ class=gb4>Sign in</a></nobr></div><div class=gbh style=left:0></div><div class=gbh
112
+ style=right:0></div></div><iframe name="wgjf" style="display:none"></iframe><center><br
113
+ clear="all" id="lgpd"><div id="lga"><img alt="Google" height="95" src="/intl/en_ALL/images/srpr/logo1w.png"
114
+ width="275" id="hplogo" onload="window.lol&&lol()" style="padding:28px 0 14px"><br><br></div><form
115
+ action="/search" name="f"><table cellpadding="0" cellspacing="0"><tr valign="top"><td
116
+ width="25%">&nbsp;</td><td align="center" nowrap="nowrap"><input name="ie"
117
+ value="ISO-8859-1" type="hidden"><input value="en" name="hl" type="hidden"><input
118
+ name="source" type="hidden" value="hp"><div class="ds" style="height:32px;margin:4px
119
+ 0"><input autocomplete="off" class="lst" value="" title="Google Search" maxlength="2048"
120
+ name="q" size="57" style="color:#000;margin:0;padding:5px 8px 0 6px;vertical-align:top"></div><br
121
+ style="line-height:0"><span class="ds"><span class="lsbb"><input class="lsb"
122
+ value="Google Search" name="btnG" type="submit"></span></span><span class="ds"><span
123
+ class="lsbb"><input class="lsb" value="I''m Feeling Lucky" name="btnI" type="submit"
124
+ onclick="if(this.form.q.value)this.checked=1; else top.location=''/doodles/''"></span></span></td><td
125
+ class="fl sblc" align="left" nowrap="nowrap" width="25%"><a href="/advanced_search?hl=en&amp;authuser=0">Advanced
126
+ search</a><a href="/language_tools?hl=en&amp;authuser=0">Language tools</a></td></tr></table><input
127
+ type="hidden" id="gbv" name="gbv" value="1"></form><div id="gac_scont"></div><div
128
+ style="font-size:83%;min-height:3.5em"><br><div id="prm"><font id="hpplink"
129
+ size="-1" style="behavior:url(#default#userdata)"><span style="color:red"></span>Love
130
+ the free and open Internet? <a href="https://www.google.com/takeaction/?utm_source=google&amp;utm_medium=hpp&amp;utm_campaign=12032012freeandopen_en"
131
+ onclick="google.promos&&google.promos.link&& google.promos.link.cl()">Tell
132
+ the world''s governments</a> to keep it that way.</font><br><br><br><script
133
+ type="text/javascript">(function(){var d={promos:{}};d.promos.localStorage={};d.promos.localStorage.isLocalstorageSupported=function(){try{return"object"==typeof
134
+ window.localStorage}catch(a){return!1}};d.promos.localStorage.getPersistData=function(a){a=window.localStorage.getItem(a);return!a?"":a.toString()};d.promos.localStorage.setPersistData=function(a,b){window.localStorage.setItem(a,b)};d.promos.localStorage.removePersistData=function(a){window.localStorage.removeItem(a)};google.promos||(google.promos={});google.promos.ActionType={ACCEPT:"a",CANCEL:"c",DISMISS:"d",CLICK:"h",IMPRESSION:"i",NO_THANKS:"n",X_BUTTON:"x",MGMHP_ACCEPT:"ma",MGMHP_CANCEL:"mc",MGMHP_IMPRESSION:"mi",MGMHPPD_ACCEPT:"pa",MGMHPPD_CANCEL:"pc",MGMHPPD_IMPRESSION:"pi",MGMHPPD_NO_THANKS:"pn",MGMHPPD_NO_BUTTON:"px",MGMHPPD_DISMISS:"pd",PUSHDOWN_ACCEPT:"gpa",PUSHDOWN_IMPRESSION:"gpi",PUSHDOWN_NO_THANKS:"gpn",PUSHDOWN_NO_BUTTON:"gpx",PUSHDOWN_DISMISS:"gpd"};google.promos.sl=function(a,b,c,e){a=[c,"id="+a,"loc="+google.sn];a.push("oi=promoslinger");e&&a.push(e);google.log(b,a.join("&"))};google.promos.si=function(a,b,c,e){0.01>Math.random()&&google.promos.sl(a,b,e?e:google.promos.ActionType.IMPRESSION,c)};google.promos.spd=function(a,b,c){if(d.promos.localStorage.isLocalstorageSupported())d.promos.localStorage.setPersistData(b,c);else
135
+ if(a)try{a.setAttribute(b,c),a.save(a.id)}catch(e){google.ml(e,!1,{cause:"PERSIST_DATA_FAIL"})}};google.promos.gpd=function(a,b){if(d.promos.localStorage.isLocalstorageSupported())return
136
+ d.promos.localStorage.getPersistData(b);if(a)try{return a.load(a.id),a.getAttribute(b)}catch(c){google.ml(c,!1,{cause:"PERSIST_DATA_FAIL"})}return""};google.promos.rpd=function(a,b){if(d.promos.localStorage.isLocalstorageSupported())d.promos.localStorage.removePersistData(b);else
137
+ if(a)try{a.load(a.id),a.removeAttribute(b),a.save(a.id)}catch(c){google.ml(c,!1,{cause:"PERSIST_DATA_FAIL"})}};google.promos.aeh=function(a,b,c){a.addEventListener?a.addEventListener(b,c,!1):a.attachEvent&&a.attachEvent("on"+b,c)};})();</script><script
138
+ type="text/javascript">(function(){var c,e,g=0,h;google.promos.link||(google.promos.link={});google.promos.link.getExtraLogData_=function(b){var
139
+ a=document.getElementById(h);if(a){var f=e+"_upccb",d=parseInt(google.promos.gpd(a,f)||0,10);d++;g++;google.promos.spd(a,f,d);a=[["upcc",g].join("="),["upccb",d].join("=")];b&&a.push(b);return
140
+ a.join("&")}};google.promos.link.cl=function(b){try{google.promos.sl(e,c,google.promos.ActionType.CLICK,google.promos.link.getExtraLogData_(b))}catch(a){google.ml(a,!1,{cause:c+"_CL"})}};google.promos.link.init=function(b,a,f){try{e=b,c=a,h=f,google.promos.si(e,c)}catch(d){google.ml(d,!1,{cause:c+"_INIT"})}};})();</script><script>(function(){var
141
+ sourceWebappPromoID=1579001;var payloadType=3;google.promos.link.init(sourceWebappPromoID,payloadType,''hpplink'');})();</script></div></div><span
142
+ id="footer"><div style="font-size:10pt"><div id="fll" style="margin:19px auto;text-align:center"><a
143
+ href="/intl/en/ads/">Advertising&nbsp;Programs</a><a href="/services/">Business
144
+ Solutions</a><a href="https://plus.google.com/116899029375914044550" rel="publisher">+Google</a><a
145
+ href="/intl/en/about.html">About Google</a></div></div><p style="color:#767676;font-size:8pt">&copy;
146
+ 2012 - <a href="/intl/en/policies/">Privacy & Terms</a></p></span></center><div
147
+ id=xjsd></div><div id=xjsi><script>if(google.y)google.y.first=[];(function(){var
148
+ b;function c(a){window.setTimeout(function(){var d=document.createElement("script");d.src=a;document.getElementById("xjsd").appendChild(d)},0)}google.dljp=function(a){b=a;google.xjsi||(google.xjsu=a,c(b))};google.dlj=c;})();
149
+
150
+ if(!google.xjs){google.dstr=[];google.rein=[];window._=window._||{};window._._DumpException=function(e){throw
151
+ e};if(google.timers&&google.timers.load.t){google.timers.load.t.xjsls=new
152
+ Date().getTime();}google.dljp(''/xjs/_/js/hp/sb_he,pcc/rt\x3dj/ver\x3dekMxmVjFIzI.en_US./d\x3d1/sv\x3d1/rs\x3dAItRSTM0lksRtI2VxMWJM1mGGSAc7V2OnQ'');google.xjs=1;}google.pmc={sb:{"agen":false,"cgen":true,"client":"heirloom-hp","dh":true,"ds":"","eqch":true,"fl":true,"host":"google.com","jsonp":true,"msgs":{"lcky":"I\u0026#39;m
153
+ Feeling Lucky","lml":"Learn more","oskt":"Input tools","psrc":"This search
154
+ was removed from your \u003Ca href=\"/history\"\u003EWeb History\u003C/a\u003E","psrl":"Remove","sbit":"Search
155
+ by image","srch":"Google Search"},"ovr":{"l":1,"ms":1},"pq":"","qcpw":false,"scd":10,"sce":5,"stok":"T6XUP3D9Euph7X6BWXXXesAOH9Q"},pcc:{}};google.y.first.push(function(){if(google.med){google.med(''init'');google.initHistory();google.med(''history'');}google.History&&google.History.initialize(''/?foo\x3dbar'');google.hs&&google.hs.init&&google.hs.init()});if(google.j&&google.j.en&&google.j.xi){window.setTimeout(google.j.xi,0);}</script></div><script>(function(){var
156
+ b,c,d,e;function g(a,f){a.removeEventListener?(a.removeEventListener("load",f,!1),a.removeEventListener("error",f,!1)):(a.detachEvent("onload",f),a.detachEvent("onerror",f))}function
157
+ h(a){e=(new Date).getTime();++c;a=a||window.event;a=a.target||a.srcElement;g(a,h)}var
158
+ j=document.getElementsByTagName("img");b=j.length;
159
+
160
+ for(var k=c=0,l;k<b;++k)l=j[k],l.complete||"string"!=typeof l.src||!l.src?++c:l.addEventListener?(l.addEventListener("load",h,!1),l.addEventListener("error",h,!1)):(l.attachEvent("onload",h),l.attachEvent("onerror",h));d=b-c;
161
+
162
+ function m(){if(google.timers.load.t){google.timers.load.t.ol=(new Date).getTime();google.timers.load.t.iml=e;google.kCSI.imc=c;google.kCSI.imn=b;google.kCSI.imp=d;void
163
+ 0!==google.stt&&(google.kCSI.stt=google.stt);google.csiReport&&google.csiReport()}}window.addEventListener?window.addEventListener("load",m,!1):window.attachEvent&&window.attachEvent("onload",m);google.timers.load.t.prt=e=(new
164
+ Date).getTime();})();
165
+
166
+ </script></body></html>'
167
+ http_version: '1.1'
168
+ recorded_at: Mon, 03 Dec 2012 22:11:13 GMT
169
+ recorded_with: VCR 2.3.0
@@ -0,0 +1,169 @@
1
+ ---
2
+ http_interactions:
3
+ - request:
4
+ method: get
5
+ uri: http://www.google.com/
6
+ body:
7
+ encoding: US-ASCII
8
+ string: ''
9
+ headers:
10
+ accept:
11
+ - ! '*/*; q=0.5, application/xml'
12
+ accept-encoding:
13
+ - gzip, deflate
14
+ user-agent:
15
+ - Ruby
16
+ response:
17
+ status:
18
+ code: 200
19
+ message: OK
20
+ headers:
21
+ date:
22
+ - Mon, 03 Dec 2012 22:03:57 GMT
23
+ expires:
24
+ - '-1'
25
+ cache-control:
26
+ - private, max-age=0
27
+ content-type:
28
+ - text/html; charset=ISO-8859-1
29
+ set-cookie:
30
+ - PREF=ID=94e6df9229a73ac0:FF=0:TM=1354572237:LM=1354572237:S=6bAtMVHUYfB8wx3L;
31
+ expires=Wed, 03-Dec-2014 22:03:57 GMT; path=/; domain=.google.com
32
+ - NID=66=nNr0I0VCUDllfq0uxfCQqSd3wNnhYb2cFIXl3QhPCglSbYFjEbX58axffT4Ekie0l-HTCQCpQJueWE9qmu7JcWlvtcbbQrGMnYqFEdaS7YpVNM8RG9zy6w9RbFUYJ_bZ;
33
+ expires=Tue, 04-Jun-2013 22:03:57 GMT; path=/; domain=.google.com; HttpOnly
34
+ p3p:
35
+ - CP="This is not a P3P policy! See http://www.google.com/support/accounts/bin/answer.py?hl=en&answer=151657
36
+ for more info."
37
+ server:
38
+ - gws
39
+ x-xss-protection:
40
+ - 1; mode=block
41
+ x-frame-options:
42
+ - SAMEORIGIN
43
+ transfer-encoding:
44
+ - chunked
45
+ body:
46
+ encoding: US-ASCII
47
+ string: ! '<!doctype html><html itemscope="itemscope" itemtype="http://schema.org/WebPage"><head><meta
48
+ content="Search the world''s information, including webpages, images, videos
49
+ and more. Google has many special features to help you find exactly what you''re
50
+ looking for." name="description"><meta content="noodp" name="robots"><meta
51
+ itemprop="image" content="/images/google_favicon_128.png"><title>Google</title><script>(function(){
52
+
53
+ window.google={kEI:"zSG9UIGGK4qNigLo5oHgDg",getEI:function(a){for(var b;a&&(!a.getAttribute||!(b=a.getAttribute("eid")));)a=a.parentNode;return
54
+ b||google.kEI},https:function(){return"https:"==window.location.protocol},kEXPI:"17259,39523,39976,40363,4000116,4000473,4000565,4000945,4000955,4001372,4001456,4001569,4001855,4001933,4001959,4001966,4002000,4002036,4002156,4002161,4002240,4002274,4002348,4002359,4002391,4002436,4002460,4002466,4002510,4002562,4002710,4002771,4002789",kCSI:{e:"17259,39523,39976,40363,4000116,4000473,4000565,4000945,4000955,4001372,4001456,4001569,4001855,4001933,4001959,4001966,4002000,4002036,4002156,4002161,4002240,4002274,4002348,4002359,4002391,4002436,4002460,4002466,4002510,4002562,4002710,4002771,4002789",ei:"zSG9UIGGK4qNigLo5oHgDg"},authuser:0,ml:function(){},kHL:"en",time:function(){return(new
55
+ Date).getTime()},log:function(a,
56
+
57
+ b,c,j){var d=new Image,f=google.lc,e=google.li,g="";d.onerror=d.onload=d.onabort=function(){delete
58
+ f[e]};f[e]=d;!c&&-1==b.search("&ei=")&&(g="&ei="+google.getEI(j));c=c||"/gen_204?atyp=i&ct="+a+"&cad="+b+g+"&zx="+google.time();a=/^http:/i;a.test(c)&&google.https()?(google.ml(Error("GLMM"),!1,{src:c}),delete
59
+ f[e]):(d.src=c,google.li=e+1)},lc:[],li:0,Toolbelt:{},y:{},x:function(a,b){google.y[a.id]=[a,b];return!1}};})();
60
+
61
+ window.google.sn="webhp";window.google.timers={};window.google.startTick=function(a,b){window.google.timers[a]={t:{start:(new
62
+ Date).getTime()},bfr:!(!b)}};window.google.tick=function(a,b,c){if(!window.google.timers[a])google.startTick(a);window.google.timers[a].t[b]=c||(new
63
+ Date).getTime()};google.startTick("load",true);try{}catch(u){}
64
+
65
+ var _gjwl=location;function _gjuc(){var a=_gjwl.href.indexOf("#");if(0<=a&&(a=_gjwl.href.substring(a),0<a.indexOf("&q=")||0<=a.indexOf("#q=")))if(a=a.substring(1),-1==a.indexOf("#")){for(var
66
+ d=0;d<a.length;){var b=d;"&"==a.charAt(b)&&++b;var c=a.indexOf("&",b);-1==c&&(c=a.length);b=a.substring(b,c);if(0==b.indexOf("fp="))a=a.substring(0,d)+a.substring(c,a.length),c=d;else
67
+ if("cad=h"==b)return 0;d=c}_gjwl.href="/search?"+a+"&cad=h";return 1}return
68
+ 0}
69
+
70
+ function _gjp(){(!window._gjwl.hash||!window._gjuc())&&setTimeout(_gjp,500)};
71
+
72
+ window._gjp&&_gjp();</script><style>#gbar,#guser{font-size:13px;padding-top:1px
73
+ !important;}#gbar{height:22px}#guser{padding-bottom:7px !important;text-align:right}.gbh,.gbd{border-top:1px
74
+ solid #c9d7f1;font-size:1px}.gbh{height:0;position:absolute;top:24px;width:100%}@media
75
+ all{.gb1{height:22;margin-right:.5em;vertical-align:top}#gbar{float:left}}a.gb1,a.gb4{text-decoration:underline
76
+ !important}a.gb1,a.gb4{color:#00c !important}.gbi .gb4{color:#dd8e27 !important}.gbf
77
+ .gb4{color:#900 !important}</style><style id="gstyle">body{margin:0;overflow-y:scroll}#gog{padding:3px
78
+ 8px 0}td{line-height:.8em}.gac_m td{line-height:17px}form{margin-bottom:20px}body,td,a,p,.h{font-family:arial,sans-serif}.h{color:#36c;font-size:20px}.q{color:#00c}.ts
79
+ td{padding:0}.ts{border-collapse:collapse}em{font-weight:bold;font-style:normal}.lst{height:25px;width:496px}.gsfi,.lst{font:18px
80
+ arial,sans-serif}.gsfs{font:17px arial,sans-serif}.ds{display:-moz-inline-box;display:inline-block;margin:3px
81
+ 0 4px;margin-left:4px}input{font-family:inherit}a.gb1,a.gb2,a.gb3,a.gb4{color:#11c
82
+ !important}body{background:#fff;color:black}a{color:#11c;text-decoration:none}a:hover,a:active{text-decoration:underline}.fl
83
+ a{color:#36c}a:visited{color:#551a8b}a.gb1,a.gb4{text-decoration:underline}a.gb3:hover{text-decoration:none}#ghead
84
+ a.gb2:hover{color:#fff!important}.sblc{padding-top:5px}.sblc a{display:block;margin:2px
85
+ 0;margin-left:13px;font-size:11px;}.lsbb{background:#eee;border:solid 1px;border-color:#ccc
86
+ #999 #999 #ccc;height:30px;display:block}.ftl,#fll a{display:inline-block;margin:0
87
+ 12px}.lsb{background:url(/images/srpr/nav_logo80.png) 0 -258px repeat-x;border:none;color:#000;cursor:pointer;height:30px;margin:0;outline:0;font:15px
88
+ arial,sans-serif;vertical-align:top}.lsb:active{background:#ccc}.lst:focus{outline:none}#addlang
89
+ a{padding:0 3px}.gac_v div{display:none}.gac_v .gac_v2,.gac_bt{display:block!important}table.gssb_c{z-index:986 }.nbcl{background:url(/images/srpr/nav_logo80.png)
90
+ no-repeat ;height:px;width:px}</style><script></script> </head><body dir="ltr"
91
+ bgcolor="#fff"><script>(function(){var src=''/images/srpr/nav_logo80.png'';var
92
+ iesg=false;document.body.onload = function(){window.n && window.n();if (document.images){new
93
+ Image().src=src;}
94
+
95
+ if (!iesg){document.f&&document.f.q.focus();document.gbqf&&document.gbqf.q.focus();}
96
+
97
+ }
98
+
99
+ })();</script><textarea id="csi" style="display:none"></textarea><div id="mngb"><div
100
+ id=gbar><nobr><b class=gb1>Search</b> <a class=gb1 href="http://www.google.com/imghp?hl=en&tab=wi">Images</a>
101
+ <a class=gb1 href="http://maps.google.com/maps?hl=en&tab=wl">Maps</a> <a class=gb1
102
+ href="https://play.google.com/?hl=en&tab=w8">Play</a> <a class=gb1 href="http://www.youtube.com/?tab=wy">YouTube</a>
103
+ <a class=gb1 href="http://news.google.com/nwshp?hl=en&tab=wn">News</a> <a
104
+ class=gb1 href="https://mail.google.com/mail/?tab=wm">Gmail</a> <a class=gb1
105
+ href="https://drive.google.com/?tab=wo">Drive</a> <a class=gb1 style="text-decoration:none"
106
+ href="http://www.google.com/intl/en/options/"><u>More</u> &raquo;</a></nobr></div><div
107
+ id=guser width=100%><nobr><span id=gbn class=gbi></span><span id=gbf class=gbf></span><span
108
+ id=gbe></span><a href="http://www.google.com/history/optout?hl=en" class=gb4>Web
109
+ History</a> | <a href="/preferences?hl=en" class=gb4>Settings</a> | <a target=_top
110
+ id=gb_70 href="https://accounts.google.com/ServiceLogin?hl=en&continue=http://www.google.com/"
111
+ class=gb4>Sign in</a></nobr></div><div class=gbh style=left:0></div><div class=gbh
112
+ style=right:0></div></div><iframe name="wgjf" style="display:none"></iframe><center><br
113
+ clear="all" id="lgpd"><div id="lga"><img alt="Google" height="95" src="/intl/en_ALL/images/srpr/logo1w.png"
114
+ width="275" id="hplogo" onload="window.lol&&lol()" style="padding:28px 0 14px"><br><br></div><form
115
+ action="/search" name="f"><table cellpadding="0" cellspacing="0"><tr valign="top"><td
116
+ width="25%">&nbsp;</td><td align="center" nowrap="nowrap"><input name="ie"
117
+ value="ISO-8859-1" type="hidden"><input value="en" name="hl" type="hidden"><input
118
+ name="source" type="hidden" value="hp"><div class="ds" style="height:32px;margin:4px
119
+ 0"><input autocomplete="off" class="lst" value="" title="Google Search" maxlength="2048"
120
+ name="q" size="57" style="color:#000;margin:0;padding:5px 8px 0 6px;vertical-align:top"></div><br
121
+ style="line-height:0"><span class="ds"><span class="lsbb"><input class="lsb"
122
+ value="Google Search" name="btnG" type="submit"></span></span><span class="ds"><span
123
+ class="lsbb"><input class="lsb" value="I''m Feeling Lucky" name="btnI" type="submit"
124
+ onclick="if(this.form.q.value)this.checked=1; else top.location=''/doodles/''"></span></span></td><td
125
+ class="fl sblc" align="left" nowrap="nowrap" width="25%"><a href="/advanced_search?hl=en&amp;authuser=0">Advanced
126
+ search</a><a href="/language_tools?hl=en&amp;authuser=0">Language tools</a></td></tr></table><input
127
+ type="hidden" id="gbv" name="gbv" value="1"></form><div id="gac_scont"></div><div
128
+ style="font-size:83%;min-height:3.5em"><br><div id="prm"><font id="hpplink"
129
+ size="-1" style="behavior:url(#default#userdata)"><span style="color:red"></span>Love
130
+ the free and open Internet? <a href="https://www.google.com/takeaction/?utm_source=google&amp;utm_medium=hpp&amp;utm_campaign=12032012freeandopen_en"
131
+ onclick="google.promos&&google.promos.link&& google.promos.link.cl()">Tell
132
+ the world''s governments</a> to keep it that way.</font><br><br><br><script
133
+ type="text/javascript">(function(){var d={promos:{}};d.promos.localStorage={};d.promos.localStorage.isLocalstorageSupported=function(){try{return"object"==typeof
134
+ window.localStorage}catch(a){return!1}};d.promos.localStorage.getPersistData=function(a){a=window.localStorage.getItem(a);return!a?"":a.toString()};d.promos.localStorage.setPersistData=function(a,b){window.localStorage.setItem(a,b)};d.promos.localStorage.removePersistData=function(a){window.localStorage.removeItem(a)};google.promos||(google.promos={});google.promos.ActionType={ACCEPT:"a",CANCEL:"c",DISMISS:"d",CLICK:"h",IMPRESSION:"i",NO_THANKS:"n",X_BUTTON:"x",MGMHP_ACCEPT:"ma",MGMHP_CANCEL:"mc",MGMHP_IMPRESSION:"mi",MGMHPPD_ACCEPT:"pa",MGMHPPD_CANCEL:"pc",MGMHPPD_IMPRESSION:"pi",MGMHPPD_NO_THANKS:"pn",MGMHPPD_NO_BUTTON:"px",MGMHPPD_DISMISS:"pd",PUSHDOWN_ACCEPT:"gpa",PUSHDOWN_IMPRESSION:"gpi",PUSHDOWN_NO_THANKS:"gpn",PUSHDOWN_NO_BUTTON:"gpx",PUSHDOWN_DISMISS:"gpd"};google.promos.sl=function(a,b,c,e){a=[c,"id="+a,"loc="+google.sn];a.push("oi=promoslinger");e&&a.push(e);google.log(b,a.join("&"))};google.promos.si=function(a,b,c,e){0.01>Math.random()&&google.promos.sl(a,b,e?e:google.promos.ActionType.IMPRESSION,c)};google.promos.spd=function(a,b,c){if(d.promos.localStorage.isLocalstorageSupported())d.promos.localStorage.setPersistData(b,c);else
135
+ if(a)try{a.setAttribute(b,c),a.save(a.id)}catch(e){google.ml(e,!1,{cause:"PERSIST_DATA_FAIL"})}};google.promos.gpd=function(a,b){if(d.promos.localStorage.isLocalstorageSupported())return
136
+ d.promos.localStorage.getPersistData(b);if(a)try{return a.load(a.id),a.getAttribute(b)}catch(c){google.ml(c,!1,{cause:"PERSIST_DATA_FAIL"})}return""};google.promos.rpd=function(a,b){if(d.promos.localStorage.isLocalstorageSupported())d.promos.localStorage.removePersistData(b);else
137
+ if(a)try{a.load(a.id),a.removeAttribute(b),a.save(a.id)}catch(c){google.ml(c,!1,{cause:"PERSIST_DATA_FAIL"})}};google.promos.aeh=function(a,b,c){a.addEventListener?a.addEventListener(b,c,!1):a.attachEvent&&a.attachEvent("on"+b,c)};})();</script><script
138
+ type="text/javascript">(function(){var c,e,g=0,h;google.promos.link||(google.promos.link={});google.promos.link.getExtraLogData_=function(b){var
139
+ a=document.getElementById(h);if(a){var f=e+"_upccb",d=parseInt(google.promos.gpd(a,f)||0,10);d++;g++;google.promos.spd(a,f,d);a=[["upcc",g].join("="),["upccb",d].join("=")];b&&a.push(b);return
140
+ a.join("&")}};google.promos.link.cl=function(b){try{google.promos.sl(e,c,google.promos.ActionType.CLICK,google.promos.link.getExtraLogData_(b))}catch(a){google.ml(a,!1,{cause:c+"_CL"})}};google.promos.link.init=function(b,a,f){try{e=b,c=a,h=f,google.promos.si(e,c)}catch(d){google.ml(d,!1,{cause:c+"_INIT"})}};})();</script><script>(function(){var
141
+ sourceWebappPromoID=1579001;var payloadType=3;google.promos.link.init(sourceWebappPromoID,payloadType,''hpplink'');})();</script></div></div><span
142
+ id="footer"><div style="font-size:10pt"><div id="fll" style="margin:19px auto;text-align:center"><a
143
+ href="/intl/en/ads/">Advertising&nbsp;Programs</a><a href="/services/">Business
144
+ Solutions</a><a href="https://plus.google.com/116899029375914044550" rel="publisher">+Google</a><a
145
+ href="/intl/en/about.html">About Google</a></div></div><p style="color:#767676;font-size:8pt">&copy;
146
+ 2012 - <a href="/intl/en/policies/">Privacy & Terms</a></p></span></center><div
147
+ id=xjsd></div><div id=xjsi><script>if(google.y)google.y.first=[];(function(){var
148
+ b;function c(a){window.setTimeout(function(){var d=document.createElement("script");d.src=a;document.getElementById("xjsd").appendChild(d)},0)}google.dljp=function(a){b=a;google.xjsi||(google.xjsu=a,c(b))};google.dlj=c;})();
149
+
150
+ if(!google.xjs){google.dstr=[];google.rein=[];window._=window._||{};window._._DumpException=function(e){throw
151
+ e};if(google.timers&&google.timers.load.t){google.timers.load.t.xjsls=new
152
+ Date().getTime();}google.dljp(''/xjs/_/js/hp/sb_he,pcc/rt\x3dj/ver\x3dekMxmVjFIzI.en_US./d\x3d1/sv\x3d1/rs\x3dAItRSTM0lksRtI2VxMWJM1mGGSAc7V2OnQ'');google.xjs=1;}google.pmc={sb:{"agen":false,"cgen":true,"client":"heirloom-hp","dh":true,"ds":"","eqch":true,"fl":true,"host":"google.com","jsonp":true,"msgs":{"lcky":"I\u0026#39;m
153
+ Feeling Lucky","lml":"Learn more","oskt":"Input tools","psrc":"This search
154
+ was removed from your \u003Ca href=\"/history\"\u003EWeb History\u003C/a\u003E","psrl":"Remove","sbit":"Search
155
+ by image","srch":"Google Search"},"ovr":{"l":1,"ms":1},"pq":"","qcpw":false,"scd":10,"sce":5,"stok":"XiSEhY3Wy8NP0yq7qMI_SslvMHg"},pcc:{}};google.y.first.push(function(){if(google.med){google.med(''init'');google.initHistory();google.med(''history'');}google.History&&google.History.initialize(''/'');google.hs&&google.hs.init&&google.hs.init()});if(google.j&&google.j.en&&google.j.xi){window.setTimeout(google.j.xi,0);}</script></div><script>(function(){var
156
+ b,c,d,e;function g(a,f){a.removeEventListener?(a.removeEventListener("load",f,!1),a.removeEventListener("error",f,!1)):(a.detachEvent("onload",f),a.detachEvent("onerror",f))}function
157
+ h(a){e=(new Date).getTime();++c;a=a||window.event;a=a.target||a.srcElement;g(a,h)}var
158
+ j=document.getElementsByTagName("img");b=j.length;
159
+
160
+ for(var k=c=0,l;k<b;++k)l=j[k],l.complete||"string"!=typeof l.src||!l.src?++c:l.addEventListener?(l.addEventListener("load",h,!1),l.addEventListener("error",h,!1)):(l.attachEvent("onload",h),l.attachEvent("onerror",h));d=b-c;
161
+
162
+ function m(){if(google.timers.load.t){google.timers.load.t.ol=(new Date).getTime();google.timers.load.t.iml=e;google.kCSI.imc=c;google.kCSI.imn=b;google.kCSI.imp=d;void
163
+ 0!==google.stt&&(google.kCSI.stt=google.stt);google.csiReport&&google.csiReport()}}window.addEventListener?window.addEventListener("load",m,!1):window.attachEvent&&window.attachEvent("onload",m);google.timers.load.t.prt=e=(new
164
+ Date).getTime();})();
165
+
166
+ </script></body></html>'
167
+ http_version: '1.1'
168
+ recorded_at: Mon, 03 Dec 2012 22:03:57 GMT
169
+ recorded_with: VCR 2.3.0
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: dubdubdub
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.1
4
+ version: 0.1.0
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -11,6 +11,22 @@ bindir: bin
11
11
  cert_chain: []
12
12
  date: 2012-12-03 00:00:00.000000000 Z
13
13
  dependencies:
14
+ - !ruby/object:Gem::Dependency
15
+ name: rest-client
16
+ requirement: !ruby/object:Gem::Requirement
17
+ none: false
18
+ requirements:
19
+ - - ! '>='
20
+ - !ruby/object:Gem::Version
21
+ version: '0'
22
+ type: :runtime
23
+ prerelease: false
24
+ version_requirements: !ruby/object:Gem::Requirement
25
+ none: false
26
+ requirements:
27
+ - - ! '>='
28
+ - !ruby/object:Gem::Version
29
+ version: '0'
14
30
  - !ruby/object:Gem::Dependency
15
31
  name: rspec
16
32
  requirement: !ruby/object:Gem::Requirement
@@ -138,6 +154,9 @@ files:
138
154
  - spec/vcr/follow_url/proxied.yml
139
155
  - spec/vcr/follow_url/proxy.yml
140
156
  - spec/vcr/follow_url/proxy_forbidden.yml
157
+ - spec/vcr/get/basic.yml
158
+ - spec/vcr/get/params.yml
159
+ - spec/vcr/get/proxy.yml
141
160
  homepage: http://github.com/axsuul/dubdubdub
142
161
  licenses:
143
162
  - MIT
@@ -153,7 +172,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
153
172
  version: '0'
154
173
  segments:
155
174
  - 0
156
- hash: -3573896982270163900
175
+ hash: -2986985482614127435
157
176
  required_rubygems_version: !ruby/object:Gem::Requirement
158
177
  none: false
159
178
  requirements: