patron 0.4.10 → 0.4.11
Sign up to get free protection for your applications and to get access to all the features.
- data/.autotest +15 -0
- data/.gitignore +6 -0
- data/.rspec +0 -0
- data/.rvmrc +1 -0
- data/Gemfile +2 -0
- data/Gemfile.lock +31 -0
- data/Rakefile +17 -78
- data/ext/patron/.gitignore +4 -0
- data/lib/patron.rb +1 -7
- data/lib/patron/request.rb +3 -0
- data/lib/patron/version.rb +3 -0
- data/patron.gemspec +27 -0
- data/script/console +11 -0
- data/script/test_server +113 -0
- data/spec/session_spec.rb +12 -12
- data/spec/spec_helper.rb +1 -9
- metadata +89 -35
- data/VERSION.yml +0 -5
- data/spec/spec.opts +0 -6
data/.autotest
ADDED
@@ -0,0 +1,15 @@
|
|
1
|
+
Autotest.add_hook :initialize do |at|
|
2
|
+
at.clear_mappings
|
3
|
+
|
4
|
+
at.add_mapping(%r{^spec/.+_spec\.rb$}) do |filename,_|
|
5
|
+
filename
|
6
|
+
end
|
7
|
+
|
8
|
+
at.add_mapping(%r{^lib/patron/(.+)\.rb$}) do |_,match|
|
9
|
+
[ "spec/#{match[1]}_spec.rb" ]
|
10
|
+
end
|
11
|
+
|
12
|
+
at.add_mapping(%r{^spec/spec_helper\.rb$}) do
|
13
|
+
at.files_matching(%r{^spec/.+_spec\.rb$})
|
14
|
+
end
|
15
|
+
end
|
data/.rspec
ADDED
File without changes
|
data/.rvmrc
ADDED
@@ -0,0 +1 @@
|
|
1
|
+
rvm gemset use patron
|
data/Gemfile
ADDED
data/Gemfile.lock
ADDED
@@ -0,0 +1,31 @@
|
|
1
|
+
PATH
|
2
|
+
remote: .
|
3
|
+
specs:
|
4
|
+
patron (0.4.10)
|
5
|
+
|
6
|
+
GEM
|
7
|
+
remote: http://rubygems.org/
|
8
|
+
specs:
|
9
|
+
diff-lcs (1.1.2)
|
10
|
+
rake (0.8.7)
|
11
|
+
rake-compiler (0.7.5)
|
12
|
+
rake
|
13
|
+
rcov (0.9.9)
|
14
|
+
rspec (2.3.0)
|
15
|
+
rspec-core (~> 2.3.0)
|
16
|
+
rspec-expectations (~> 2.3.0)
|
17
|
+
rspec-mocks (~> 2.3.0)
|
18
|
+
rspec-core (2.3.1)
|
19
|
+
rspec-expectations (2.3.0)
|
20
|
+
diff-lcs (~> 1.1.2)
|
21
|
+
rspec-mocks (2.3.0)
|
22
|
+
|
23
|
+
PLATFORMS
|
24
|
+
ruby
|
25
|
+
|
26
|
+
DEPENDENCIES
|
27
|
+
bundler (>= 1.0.0)
|
28
|
+
patron!
|
29
|
+
rake-compiler (~> 0.7.5)
|
30
|
+
rcov (~> 0.9.9)
|
31
|
+
rspec (~> 2.3.0)
|
data/Rakefile
CHANGED
@@ -21,73 +21,22 @@
|
|
21
21
|
## THE SOFTWARE.
|
22
22
|
##
|
23
23
|
## -------------------------------------------------------------------
|
24
|
-
require 'yaml'
|
25
24
|
require 'rake/clean'
|
26
25
|
require 'rake/rdoctask'
|
27
|
-
require '
|
28
|
-
require '
|
29
|
-
require '
|
30
|
-
|
31
|
-
|
32
|
-
|
33
|
-
|
34
|
-
|
35
|
-
SESSION_SO = "#{EXT_DIR}/session_ext.#{CONFIG['DLEXT']}"
|
36
|
-
SESSION_SRC = "#{EXT_DIR}/session_ext.c"
|
37
|
-
|
38
|
-
CLEAN.include FileList["#{EXT_DIR}/*"].exclude(/^.*\.(rb|c)$/)
|
39
|
-
CLOBBER.include %w( doc coverage pkg )
|
40
|
-
|
41
|
-
module Git
|
42
|
-
class Lib
|
43
|
-
def tag(tag)
|
44
|
-
# Force an annotated tag
|
45
|
-
command('tag', [tag, '-a', '-m', tag])
|
46
|
-
end
|
47
|
-
end
|
48
|
-
end
|
49
|
-
|
50
|
-
Jeweler::Tasks.new do |s|
|
51
|
-
s.name = 'patron'
|
52
|
-
s.platform = Gem::Platform::RUBY
|
53
|
-
s.author = 'Phillip Toland'
|
54
|
-
s.email = 'phil.toland@gmail.com'
|
55
|
-
s.homepage = 'http://github.com/toland/Patron'
|
56
|
-
s.rubyforge_project = 'patron'
|
57
|
-
s.summary = 'Patron HTTP client'
|
58
|
-
s.description = 'Ruby HTTP client library based on libcurl'
|
59
|
-
|
60
|
-
s.extensions << 'ext/patron/extconf.rb'
|
61
|
-
s.require_paths << 'ext'
|
62
|
-
|
63
|
-
s.files = FileList['README.txt',
|
64
|
-
'VERSION.yml',
|
65
|
-
'LICENSE',
|
66
|
-
'Rakefile',
|
67
|
-
'lib/**/*',
|
68
|
-
'spec/*',
|
69
|
-
'ext/patron/*.{rb,c}']
|
70
|
-
|
71
|
-
# rdoc
|
72
|
-
s.has_rdoc = true
|
73
|
-
s.extra_rdoc_files = ['README.txt']
|
74
|
-
s.rdoc_options = ['--quiet',
|
75
|
-
'--title', "Patron documentation",
|
76
|
-
'--opname', 'index.html',
|
77
|
-
'--line-numbers',
|
78
|
-
'--main', 'README.txt',
|
79
|
-
'--inline-source']
|
26
|
+
require 'rake/extensiontask'
|
27
|
+
require 'rspec/core/rake_task'
|
28
|
+
require 'bundler'
|
29
|
+
|
30
|
+
Rake::ExtensionTask.new do |ext|
|
31
|
+
ext.name = 'session_ext' # indicate the name of the extension.
|
32
|
+
ext.ext_dir = 'ext/patron' # search for 'hello_world' inside it.
|
33
|
+
ext.lib_dir = 'lib/patron' # put binaries into this folder.
|
80
34
|
end
|
81
35
|
|
82
|
-
|
83
|
-
cd EXT_DIR do
|
84
|
-
ruby 'extconf.rb'
|
85
|
-
sh 'make'
|
86
|
-
end
|
87
|
-
end
|
36
|
+
Bundler::GemHelper.install_tasks
|
88
37
|
|
89
|
-
|
90
|
-
|
38
|
+
CLEAN.include FileList["ext/patron/*"].exclude(/^.*\.(rb|c)$/)
|
39
|
+
CLOBBER.include %w( doc coverage pkg )
|
91
40
|
|
92
41
|
desc "Start an IRB shell"
|
93
42
|
task :shell => :compile do
|
@@ -98,33 +47,23 @@ Rake::RDocTask.new do |rdoc|
|
|
98
47
|
rdoc.rdoc_dir = 'rdoc'
|
99
48
|
rdoc.title = 'Patron documentation'
|
100
49
|
rdoc.main = 'README.txt'
|
101
|
-
rdoc.options << '--line-numbers' << '--inline-source'
|
102
50
|
rdoc.rdoc_files.include('README.txt')
|
103
51
|
rdoc.rdoc_files.include('lib/**/*.rb')
|
104
52
|
end
|
105
53
|
|
106
|
-
YARD::Rake::YardocTask.new do |t|
|
107
|
-
t.files = ['lib/**/*.rb']
|
108
|
-
t.options = ['--readme', 'README.txt']
|
109
|
-
end
|
110
|
-
|
111
54
|
desc "Run specs"
|
112
|
-
|
113
|
-
t.
|
114
|
-
t.
|
55
|
+
RSpec::Core::RakeTask.new do |t|
|
56
|
+
t.rspec_opts = %w( --colour --format progress )
|
57
|
+
t.pattern = 'spec/**/*_spec.rb'
|
115
58
|
end
|
116
59
|
|
117
60
|
task :spec => [:compile]
|
118
61
|
|
119
62
|
desc "Run specs with RCov"
|
120
|
-
|
121
|
-
t.
|
63
|
+
RSpec::Core::RakeTask.new('spec:rcov') do |t|
|
64
|
+
t.pattern = 'spec/**/*_spec.rb'
|
122
65
|
t.rcov = true
|
123
|
-
t.rcov_opts
|
124
|
-
t.rcov_opts << '--comments'
|
125
|
-
t.rcov_opts << '--exclude spec'
|
126
|
-
t.rcov_opts << '--exclude lib/magneto.rb'
|
127
|
-
t.rcov_opts << '--exclude /Library/Ruby/Gems'
|
66
|
+
t.rcov_opts = %q(--sort coverage --comments --exclude "spec")
|
128
67
|
end
|
129
68
|
|
130
69
|
task :default => :spec
|
data/lib/patron.rb
CHANGED
@@ -22,7 +22,6 @@
|
|
22
22
|
## THE SOFTWARE.
|
23
23
|
##
|
24
24
|
## -------------------------------------------------------------------
|
25
|
-
require 'yaml'
|
26
25
|
require 'pathname'
|
27
26
|
|
28
27
|
cwd = Pathname(__FILE__).dirname
|
@@ -33,11 +32,6 @@ require 'patron/session'
|
|
33
32
|
module Patron #:nodoc:
|
34
33
|
# Returns the version number of the Patron library as a string
|
35
34
|
def self.version
|
36
|
-
|
37
|
-
yaml = YAML.load_file(cwd + '/../VERSION.yml')
|
38
|
-
major = (yaml['major'] || yaml[:major]).to_i
|
39
|
-
minor = (yaml['minor'] || yaml[:minor]).to_i
|
40
|
-
patch = (yaml['patch'] || yaml[:patch]).to_i
|
41
|
-
"#{major}.#{minor}.#{patch}"
|
35
|
+
VERSION
|
42
36
|
end
|
43
37
|
end
|
data/lib/patron/request.rb
CHANGED
@@ -23,6 +23,8 @@
|
|
23
23
|
##
|
24
24
|
## -------------------------------------------------------------------
|
25
25
|
|
26
|
+
require 'cgi'
|
27
|
+
|
26
28
|
module Patron
|
27
29
|
|
28
30
|
# Represents the information necessary for an HTTP request.
|
@@ -144,6 +146,7 @@ module Patron
|
|
144
146
|
recursive = Proc.new do |h, prefix|
|
145
147
|
h.each_pair do |k,v|
|
146
148
|
key = prefix == '' ? k : "#{prefix}[#{k}]"
|
149
|
+
@action == :post ? v = CGI::escape(v.to_s) : v
|
147
150
|
v.is_a?(Hash) ? recursive.call(v, key) : pairs << "#{key}=#{v}"
|
148
151
|
end
|
149
152
|
end
|
data/patron.gemspec
ADDED
@@ -0,0 +1,27 @@
|
|
1
|
+
# -*- encoding: utf-8 -*-
|
2
|
+
require File.expand_path("../lib/patron/version", __FILE__)
|
3
|
+
|
4
|
+
Gem::Specification.new do |s|
|
5
|
+
s.name = "patron"
|
6
|
+
s.version = Patron::VERSION
|
7
|
+
s.platform = Gem::Platform::RUBY
|
8
|
+
s.authors = ["Phillip Toland"]
|
9
|
+
s.email = ["phil.toland@gmail.com"]
|
10
|
+
s.homepage = "https://github.com/toland/patron"
|
11
|
+
s.summary = "Patron HTTP Client"
|
12
|
+
s.description = "Ruby HTTP client library based on libcurl"
|
13
|
+
|
14
|
+
s.required_rubygems_version = ">= 1.3.6"
|
15
|
+
s.rubyforge_project = "patron"
|
16
|
+
|
17
|
+
s.add_development_dependency "bundler", ">= 1.0.0"
|
18
|
+
s.add_development_dependency "rake-compiler", "~> 0.7.5"
|
19
|
+
s.add_development_dependency "rspec", "~> 2.3.0"
|
20
|
+
s.add_development_dependency "rcov", "~> 0.9.9"
|
21
|
+
|
22
|
+
s.files = `git ls-files`.split("\n")
|
23
|
+
s.executables = `git ls-files`.split("\n").map{|f| f =~ /^bin\/(.*)/ ? $1 : nil}.compact
|
24
|
+
s.require_paths = ["lib", "ext"]
|
25
|
+
s.extensions = ["ext/patron/extconf.rb"]
|
26
|
+
end
|
27
|
+
|
data/script/console
ADDED
@@ -0,0 +1,11 @@
|
|
1
|
+
#!/usr/bin/env ruby
|
2
|
+
# File: script/console
|
3
|
+
irb = RUBY_PLATFORM =~ /(:?mswin|mingw)/ ? 'irb.bat' : 'irb'
|
4
|
+
|
5
|
+
cwd = File.dirname(__FILE__)
|
6
|
+
|
7
|
+
libs = " -I#{cwd + '/../lib'} -I#{cwd + '/../ext'}"
|
8
|
+
libs << " -r patron -r irb/completion"
|
9
|
+
|
10
|
+
puts "Loading Patron"
|
11
|
+
exec "#{irb} #{libs} --simple-prompt"
|
data/script/test_server
ADDED
@@ -0,0 +1,113 @@
|
|
1
|
+
#!/usr/bin/env ruby
|
2
|
+
## -------------------------------------------------------------------
|
3
|
+
##
|
4
|
+
## Patron HTTP Client: HTTP test server for integration tests
|
5
|
+
## Copyright (c) 2008 The Hive http://www.thehive.com/
|
6
|
+
##
|
7
|
+
## Permission is hereby granted, free of charge, to any person obtaining a copy
|
8
|
+
## of this software and associated documentation files (the "Software"), to deal
|
9
|
+
## in the Software without restriction, including without limitation the rights
|
10
|
+
## to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
11
|
+
## copies of the Software, and to permit persons to whom the Software is
|
12
|
+
## furnished to do so, subject to the following conditions:
|
13
|
+
##
|
14
|
+
## The above copyright notice and this permission notice shall be included in
|
15
|
+
## all copies or substantial portions of the Software.
|
16
|
+
##
|
17
|
+
## THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
18
|
+
## IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
19
|
+
## FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
20
|
+
## AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
21
|
+
## LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
22
|
+
## OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
23
|
+
## THE SOFTWARE.
|
24
|
+
##
|
25
|
+
## -------------------------------------------------------------------
|
26
|
+
require 'yaml'
|
27
|
+
require 'webrick'
|
28
|
+
include WEBrick
|
29
|
+
|
30
|
+
# This ugly little hack is necessary to make the specs pass when running
|
31
|
+
# the test_server script under Ruby 1.9. URI::Parser#to_yaml generates
|
32
|
+
# regexp representations that YAML.parse cannot parse.
|
33
|
+
class URI::Parser
|
34
|
+
def to_yaml(opts = {})
|
35
|
+
{}.to_yaml(opts)
|
36
|
+
end
|
37
|
+
end
|
38
|
+
|
39
|
+
class TestServlet < HTTPServlet::AbstractServlet
|
40
|
+
def respond_with(method, req, res)
|
41
|
+
res.body = req.to_yaml
|
42
|
+
res['Content-Type'] = "text/plain"
|
43
|
+
end
|
44
|
+
|
45
|
+
def do_GET(req,res)
|
46
|
+
respond_with(:GET, req, res)
|
47
|
+
end
|
48
|
+
|
49
|
+
def do_POST(req,res)
|
50
|
+
respond_with(:POST, req, res)
|
51
|
+
end
|
52
|
+
|
53
|
+
def do_PUT(req,res)
|
54
|
+
respond_with(:PUT, req, res)
|
55
|
+
end
|
56
|
+
|
57
|
+
def do_DELETE(req,res)
|
58
|
+
respond_with(:DELETE, req, res)
|
59
|
+
end
|
60
|
+
|
61
|
+
def do_COPY(req,res)
|
62
|
+
respond_with(:COPY, req, res)
|
63
|
+
end
|
64
|
+
end
|
65
|
+
|
66
|
+
class TimeoutServlet < HTTPServlet::AbstractServlet
|
67
|
+
def do_GET(req,res)
|
68
|
+
sleep(1.1)
|
69
|
+
end
|
70
|
+
end
|
71
|
+
|
72
|
+
class RedirectServlet < HTTPServlet::AbstractServlet
|
73
|
+
def do_GET(req,res)
|
74
|
+
res['Location'] = "http://localhost:9001/test"
|
75
|
+
res.status = 301
|
76
|
+
end
|
77
|
+
end
|
78
|
+
|
79
|
+
class SetCookieServlet < HTTPServlet::AbstractServlet
|
80
|
+
def do_GET(req, res)
|
81
|
+
res['Set-Cookie'] = "session_id=foo123"
|
82
|
+
res['Location'] = "http://localhost:9001/test"
|
83
|
+
res.status = 301
|
84
|
+
end
|
85
|
+
end
|
86
|
+
|
87
|
+
class RepetitiveHeaderServlet < HTTPServlet::AbstractServlet
|
88
|
+
def do_GET(req, res)
|
89
|
+
# the only way to get webrick to output two headers with the same name is using cookies, so that's what we'll do:
|
90
|
+
res.cookies << Cookie.new('a', '1')
|
91
|
+
res.cookies << Cookie.new('b', '2')
|
92
|
+
res['Content-Type'] = "text/plain"
|
93
|
+
res.body = "Hi."
|
94
|
+
end
|
95
|
+
end
|
96
|
+
|
97
|
+
server = WEBrick::HTTPServer.new :Port => 9001
|
98
|
+
server.mount("/test", TestServlet)
|
99
|
+
server.mount("/timeout", TimeoutServlet)
|
100
|
+
server.mount("/redirect", RedirectServlet)
|
101
|
+
server.mount("/setcookie", SetCookieServlet)
|
102
|
+
server.mount("/repetitiveheader", RepetitiveHeaderServlet)
|
103
|
+
|
104
|
+
exit_code = lambda do
|
105
|
+
begin
|
106
|
+
server.shutdown unless server.nil?
|
107
|
+
rescue Object => e
|
108
|
+
puts "Error #{__FILE__}:#{__LINE__}\n#{e.message}"
|
109
|
+
end
|
110
|
+
end
|
111
|
+
|
112
|
+
trap("INT"){exit_code.call}
|
113
|
+
server.start
|
data/spec/session_spec.rb
CHANGED
@@ -142,7 +142,7 @@ describe Patron::Session do
|
|
142
142
|
end
|
143
143
|
|
144
144
|
it "should upload a file with :put" do
|
145
|
-
response = @session.put_file("/test", "
|
145
|
+
response = @session.put_file("/test", "LICENSE")
|
146
146
|
body = YAML::load(response.body)
|
147
147
|
body.request_method.should == "PUT"
|
148
148
|
end
|
@@ -152,7 +152,7 @@ describe Patron::Session do
|
|
152
152
|
end
|
153
153
|
|
154
154
|
it "should use chunked encoding when uploading a file with :put" do
|
155
|
-
response = @session.put_file("/test", "
|
155
|
+
response = @session.put_file("/test", "LICENSE")
|
156
156
|
body = YAML::load(response.body)
|
157
157
|
body.header['transfer-encoding'].first.should == "chunked"
|
158
158
|
end
|
@@ -170,15 +170,15 @@ describe Patron::Session do
|
|
170
170
|
end
|
171
171
|
|
172
172
|
it "should upload a file with :post" do
|
173
|
-
response = @session.post_file("/test", "
|
173
|
+
response = @session.post_file("/test", "LICENSE")
|
174
174
|
body = YAML::load(response.body)
|
175
175
|
body.request_method.should == "POST"
|
176
176
|
end
|
177
|
-
|
177
|
+
|
178
178
|
it "should upload a multipart with :post" do
|
179
|
-
response = @session.post_multipart("/test", { :test_data => "123" }, { :test_file => "
|
179
|
+
response = @session.post_multipart("/test", { :test_data => "123" }, { :test_file => "LICENSE" } )
|
180
180
|
body = YAML::load(response.body)
|
181
|
-
body.request_method.should == "POST"
|
181
|
+
body.request_method.should == "POST"
|
182
182
|
end
|
183
183
|
|
184
184
|
it "should raise when no file is provided to :post" do
|
@@ -186,7 +186,7 @@ describe Patron::Session do
|
|
186
186
|
end
|
187
187
|
|
188
188
|
it "should use chunked encoding when uploading a file with :post" do
|
189
|
-
response = @session.post_file("/test", "
|
189
|
+
response = @session.post_file("/test", "LICENSE")
|
190
190
|
body = YAML::load(response.body)
|
191
191
|
body.header['transfer-encoding'].first.should == "chunked"
|
192
192
|
end
|
@@ -220,17 +220,17 @@ describe Patron::Session do
|
|
220
220
|
threads << Thread.new do
|
221
221
|
session = Patron::Session.new
|
222
222
|
session.base_url = "http://localhost:9001"
|
223
|
-
session.post_file("/test", "
|
223
|
+
session.post_file("/test", "LICENSE")
|
224
224
|
end
|
225
225
|
end
|
226
226
|
threads.each {|t| t.join }
|
227
227
|
end
|
228
228
|
|
229
229
|
it "should limit the buffer_size" do
|
230
|
-
# Buffer size is tricky to test, as it only affects the buffer size for each
|
231
|
-
# read and it's not really visible at this, higher level. It's also only a
|
232
|
-
# suggestion rather than a command so it may not even take affect. Currently
|
233
|
-
# we just test that the response completes without any issues, it would be nice
|
230
|
+
# Buffer size is tricky to test, as it only affects the buffer size for each
|
231
|
+
# read and it's not really visible at this, higher level. It's also only a
|
232
|
+
# suggestion rather than a command so it may not even take affect. Currently
|
233
|
+
# we just test that the response completes without any issues, it would be nice
|
234
234
|
# to have a more robust test here.
|
235
235
|
@session.buffer_size = 1
|
236
236
|
|
data/spec/spec_helper.rb
CHANGED
@@ -21,15 +21,7 @@
|
|
21
21
|
## THE SOFTWARE.
|
22
22
|
##
|
23
23
|
## -------------------------------------------------------------------
|
24
|
-
require '
|
25
|
-
|
26
|
-
begin
|
27
|
-
require 'spec'
|
28
|
-
rescue LoadError
|
29
|
-
require 'rubygems'
|
30
|
-
gem 'rspec'
|
31
|
-
require 'spec'
|
32
|
-
end
|
24
|
+
require 'rspec'
|
33
25
|
|
34
26
|
$:.unshift(File.dirname(__FILE__) + '/../lib')
|
35
27
|
$:.unshift(File.dirname(__FILE__) + '/../ext')
|
metadata
CHANGED
@@ -1,13 +1,12 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: patron
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
hash: 27
|
5
4
|
prerelease: false
|
6
5
|
segments:
|
7
6
|
- 0
|
8
7
|
- 4
|
9
|
-
-
|
10
|
-
version: 0.4.
|
8
|
+
- 11
|
9
|
+
version: 0.4.11
|
11
10
|
platform: ruby
|
12
11
|
authors:
|
13
12
|
- Phillip Toland
|
@@ -15,24 +14,89 @@ autorequire:
|
|
15
14
|
bindir: bin
|
16
15
|
cert_chain: []
|
17
16
|
|
18
|
-
date: 2010-
|
17
|
+
date: 2010-12-31 00:00:00 -06:00
|
19
18
|
default_executable:
|
20
|
-
dependencies:
|
21
|
-
|
19
|
+
dependencies:
|
20
|
+
- !ruby/object:Gem::Dependency
|
21
|
+
name: bundler
|
22
|
+
prerelease: false
|
23
|
+
requirement: &id001 !ruby/object:Gem::Requirement
|
24
|
+
none: false
|
25
|
+
requirements:
|
26
|
+
- - ">="
|
27
|
+
- !ruby/object:Gem::Version
|
28
|
+
segments:
|
29
|
+
- 1
|
30
|
+
- 0
|
31
|
+
- 0
|
32
|
+
version: 1.0.0
|
33
|
+
type: :development
|
34
|
+
version_requirements: *id001
|
35
|
+
- !ruby/object:Gem::Dependency
|
36
|
+
name: rake-compiler
|
37
|
+
prerelease: false
|
38
|
+
requirement: &id002 !ruby/object:Gem::Requirement
|
39
|
+
none: false
|
40
|
+
requirements:
|
41
|
+
- - ~>
|
42
|
+
- !ruby/object:Gem::Version
|
43
|
+
segments:
|
44
|
+
- 0
|
45
|
+
- 7
|
46
|
+
- 5
|
47
|
+
version: 0.7.5
|
48
|
+
type: :development
|
49
|
+
version_requirements: *id002
|
50
|
+
- !ruby/object:Gem::Dependency
|
51
|
+
name: rspec
|
52
|
+
prerelease: false
|
53
|
+
requirement: &id003 !ruby/object:Gem::Requirement
|
54
|
+
none: false
|
55
|
+
requirements:
|
56
|
+
- - ~>
|
57
|
+
- !ruby/object:Gem::Version
|
58
|
+
segments:
|
59
|
+
- 2
|
60
|
+
- 3
|
61
|
+
- 0
|
62
|
+
version: 2.3.0
|
63
|
+
type: :development
|
64
|
+
version_requirements: *id003
|
65
|
+
- !ruby/object:Gem::Dependency
|
66
|
+
name: rcov
|
67
|
+
prerelease: false
|
68
|
+
requirement: &id004 !ruby/object:Gem::Requirement
|
69
|
+
none: false
|
70
|
+
requirements:
|
71
|
+
- - ~>
|
72
|
+
- !ruby/object:Gem::Version
|
73
|
+
segments:
|
74
|
+
- 0
|
75
|
+
- 9
|
76
|
+
- 9
|
77
|
+
version: 0.9.9
|
78
|
+
type: :development
|
79
|
+
version_requirements: *id004
|
22
80
|
description: Ruby HTTP client library based on libcurl
|
23
|
-
email:
|
81
|
+
email:
|
82
|
+
- phil.toland@gmail.com
|
24
83
|
executables: []
|
25
84
|
|
26
85
|
extensions:
|
27
86
|
- ext/patron/extconf.rb
|
28
|
-
|
29
|
-
|
30
|
-
- README.txt
|
87
|
+
extra_rdoc_files: []
|
88
|
+
|
31
89
|
files:
|
90
|
+
- .autotest
|
91
|
+
- .gitignore
|
92
|
+
- .rspec
|
93
|
+
- .rvmrc
|
94
|
+
- Gemfile
|
95
|
+
- Gemfile.lock
|
32
96
|
- LICENSE
|
33
97
|
- README.txt
|
34
98
|
- Rakefile
|
35
|
-
-
|
99
|
+
- ext/patron/.gitignore
|
36
100
|
- ext/patron/extconf.rb
|
37
101
|
- ext/patron/session_ext.c
|
38
102
|
- lib/patron.rb
|
@@ -41,37 +105,30 @@ files:
|
|
41
105
|
- lib/patron/request.rb
|
42
106
|
- lib/patron/response.rb
|
43
107
|
- lib/patron/session.rb
|
108
|
+
- lib/patron/version.rb
|
109
|
+
- patron.gemspec
|
110
|
+
- script/console
|
111
|
+
- script/test_server
|
44
112
|
- spec/patron_spec.rb
|
45
113
|
- spec/request_spec.rb
|
46
114
|
- spec/response_spec.rb
|
47
115
|
- spec/session_spec.rb
|
48
|
-
- spec/spec.opts
|
49
116
|
- spec/spec_helper.rb
|
50
117
|
has_rdoc: true
|
51
|
-
homepage:
|
118
|
+
homepage: https://github.com/toland/patron
|
52
119
|
licenses: []
|
53
120
|
|
54
121
|
post_install_message:
|
55
|
-
rdoc_options:
|
56
|
-
|
57
|
-
- --title
|
58
|
-
- Patron documentation
|
59
|
-
- --opname
|
60
|
-
- index.html
|
61
|
-
- --line-numbers
|
62
|
-
- --main
|
63
|
-
- README.txt
|
64
|
-
- --inline-source
|
122
|
+
rdoc_options: []
|
123
|
+
|
65
124
|
require_paths:
|
66
125
|
- lib
|
67
126
|
- ext
|
68
|
-
- ext
|
69
127
|
required_ruby_version: !ruby/object:Gem::Requirement
|
70
128
|
none: false
|
71
129
|
requirements:
|
72
130
|
- - ">="
|
73
131
|
- !ruby/object:Gem::Version
|
74
|
-
hash: 3
|
75
132
|
segments:
|
76
133
|
- 0
|
77
134
|
version: "0"
|
@@ -80,20 +137,17 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
80
137
|
requirements:
|
81
138
|
- - ">="
|
82
139
|
- !ruby/object:Gem::Version
|
83
|
-
hash: 3
|
84
140
|
segments:
|
85
|
-
-
|
86
|
-
|
141
|
+
- 1
|
142
|
+
- 3
|
143
|
+
- 6
|
144
|
+
version: 1.3.6
|
87
145
|
requirements: []
|
88
146
|
|
89
147
|
rubyforge_project: patron
|
90
148
|
rubygems_version: 1.3.7
|
91
149
|
signing_key:
|
92
150
|
specification_version: 3
|
93
|
-
summary: Patron HTTP
|
94
|
-
test_files:
|
95
|
-
|
96
|
-
- spec/request_spec.rb
|
97
|
-
- spec/response_spec.rb
|
98
|
-
- spec/session_spec.rb
|
99
|
-
- spec/spec_helper.rb
|
151
|
+
summary: Patron HTTP Client
|
152
|
+
test_files: []
|
153
|
+
|
data/VERSION.yml
DELETED