abhay-typhoeus 0.0.22
Sign up to get free protection for your applications and to get access to all the features.
- data/.gitignore +1 -0
- data/README.textile +212 -0
- data/Rakefile +45 -0
- data/VERSION +1 -0
- data/benchmarks/profile.rb +25 -0
- data/benchmarks/vs_nethttp.rb +35 -0
- data/examples/twitter.rb +21 -0
- data/ext/typhoeus/.gitignore +6 -0
- data/ext/typhoeus/extconf.rb +23 -0
- data/ext/typhoeus/native.c +11 -0
- data/ext/typhoeus/native.h +20 -0
- data/ext/typhoeus/typhoeus_easy.c +206 -0
- data/ext/typhoeus/typhoeus_easy.h +19 -0
- data/ext/typhoeus/typhoeus_multi.c +213 -0
- data/ext/typhoeus/typhoeus_multi.h +16 -0
- data/lib/typhoeus.rb +51 -0
- data/lib/typhoeus/.gitignore +1 -0
- data/lib/typhoeus/easy.rb +210 -0
- data/lib/typhoeus/filter.rb +28 -0
- data/lib/typhoeus/multi.rb +34 -0
- data/lib/typhoeus/remote.rb +306 -0
- data/lib/typhoeus/remote_method.rb +108 -0
- data/lib/typhoeus/remote_proxy_object.rb +48 -0
- data/lib/typhoeus/response.rb +17 -0
- data/lib/typhoeus/service.rb +20 -0
- data/profilers/valgrind.rb +24 -0
- data/spec/fixtures/result_set.xml +60 -0
- data/spec/servers/app.rb +24 -0
- data/spec/servers/delay_fixture_server.rb +66 -0
- data/spec/servers/method_server.rb +51 -0
- data/spec/spec.opts +2 -0
- data/spec/spec_helper.rb +29 -0
- data/spec/typhoeus/easy_spec.rb +148 -0
- data/spec/typhoeus/filter_spec.rb +35 -0
- data/spec/typhoeus/multi_spec.rb +82 -0
- data/spec/typhoeus/remote_method_spec.rb +141 -0
- data/spec/typhoeus/remote_proxy_object_spec.rb +73 -0
- data/spec/typhoeus/remote_spec.rb +699 -0
- data/spec/typhoeus/response_spec.rb +31 -0
- data/typhoeus.gemspec +88 -0
- metadata +104 -0
@@ -0,0 +1,31 @@
|
|
1
|
+
require File.dirname(__FILE__) + '/../spec_helper'
|
2
|
+
|
3
|
+
describe Typhoeus::Response do
|
4
|
+
describe "initialize" do
|
5
|
+
it "should store response_code" do
|
6
|
+
Typhoeus::Response.new(:code => 200).code.should == 200
|
7
|
+
end
|
8
|
+
|
9
|
+
it "should store response_headers" do
|
10
|
+
Typhoeus::Response.new(:headers => "a header!").headers.should == "a header!"
|
11
|
+
end
|
12
|
+
|
13
|
+
it "should store response_body" do
|
14
|
+
Typhoeus::Response.new(:body => "a body!").body.should == "a body!"
|
15
|
+
end
|
16
|
+
|
17
|
+
it "should store request_time" do
|
18
|
+
Typhoeus::Response.new(:time => 1.23).time.should == 1.23
|
19
|
+
end
|
20
|
+
|
21
|
+
it "should store requested_url" do
|
22
|
+
response = Typhoeus::Response.new(:requested_url => "http://test.com")
|
23
|
+
response.requested_url.should == "http://test.com"
|
24
|
+
end
|
25
|
+
|
26
|
+
it "should store requested_http_method" do
|
27
|
+
response = Typhoeus::Response.new(:requested_http_method => :delete)
|
28
|
+
response.requested_http_method.should == :delete
|
29
|
+
end
|
30
|
+
end
|
31
|
+
end
|
data/typhoeus.gemspec
ADDED
@@ -0,0 +1,88 @@
|
|
1
|
+
# Generated by jeweler
|
2
|
+
# DO NOT EDIT THIS FILE
|
3
|
+
# Instead, edit Jeweler::Tasks in Rakefile, and run `rake gemspec`
|
4
|
+
# -*- encoding: utf-8 -*-
|
5
|
+
|
6
|
+
Gem::Specification.new do |s|
|
7
|
+
s.name = %q{typhoeus}
|
8
|
+
s.version = "0.0.22"
|
9
|
+
|
10
|
+
s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
|
11
|
+
s.authors = ["Paul Dix"]
|
12
|
+
s.date = %q{2009-08-26}
|
13
|
+
s.email = %q{paul@pauldix.net}
|
14
|
+
s.extensions = ["ext/typhoeus/extconf.rb"]
|
15
|
+
s.files = [
|
16
|
+
".gitignore",
|
17
|
+
"README.textile",
|
18
|
+
"Rakefile",
|
19
|
+
"VERSION",
|
20
|
+
"benchmarks/profile.rb",
|
21
|
+
"benchmarks/vs_nethttp.rb",
|
22
|
+
"examples/twitter.rb",
|
23
|
+
"ext/typhoeus/.gitignore",
|
24
|
+
"ext/typhoeus/extconf.rb",
|
25
|
+
"ext/typhoeus/native.c",
|
26
|
+
"ext/typhoeus/native.h",
|
27
|
+
"ext/typhoeus/typhoeus_easy.c",
|
28
|
+
"ext/typhoeus/typhoeus_easy.h",
|
29
|
+
"ext/typhoeus/typhoeus_multi.c",
|
30
|
+
"ext/typhoeus/typhoeus_multi.h",
|
31
|
+
"lib/typhoeus.rb",
|
32
|
+
"lib/typhoeus/.gitignore",
|
33
|
+
"lib/typhoeus/easy.rb",
|
34
|
+
"lib/typhoeus/filter.rb",
|
35
|
+
"lib/typhoeus/multi.rb",
|
36
|
+
"lib/typhoeus/remote.rb",
|
37
|
+
"lib/typhoeus/remote_method.rb",
|
38
|
+
"lib/typhoeus/remote_proxy_object.rb",
|
39
|
+
"lib/typhoeus/response.rb",
|
40
|
+
"lib/typhoeus/service.rb",
|
41
|
+
"profilers/valgrind.rb",
|
42
|
+
"spec/fixtures/result_set.xml",
|
43
|
+
"spec/servers/app.rb",
|
44
|
+
"spec/servers/delay_fixture_server.rb",
|
45
|
+
"spec/servers/method_server.rb",
|
46
|
+
"spec/spec.opts",
|
47
|
+
"spec/spec_helper.rb",
|
48
|
+
"spec/typhoeus/easy_spec.rb",
|
49
|
+
"spec/typhoeus/filter_spec.rb",
|
50
|
+
"spec/typhoeus/multi_spec.rb",
|
51
|
+
"spec/typhoeus/remote_method_spec.rb",
|
52
|
+
"spec/typhoeus/remote_proxy_object_spec.rb",
|
53
|
+
"spec/typhoeus/remote_spec.rb",
|
54
|
+
"spec/typhoeus/response_spec.rb",
|
55
|
+
"typhoeus.gemspec",
|
56
|
+
"typhoeus.gemspec",
|
57
|
+
"typhoeus.gemspec"
|
58
|
+
]
|
59
|
+
s.homepage = %q{http://github.com/pauldix/typhoeus}
|
60
|
+
s.rdoc_options = ["--charset=UTF-8"]
|
61
|
+
s.require_paths = [["lib", "ext"]]
|
62
|
+
s.rubygems_version = %q{1.3.5}
|
63
|
+
s.summary = %q{A library for interacting with web services (and building SOAs) at blinding speed.}
|
64
|
+
s.test_files = [
|
65
|
+
"spec/servers/app.rb",
|
66
|
+
"spec/servers/delay_fixture_server.rb",
|
67
|
+
"spec/servers/method_server.rb",
|
68
|
+
"spec/spec_helper.rb",
|
69
|
+
"spec/typhoeus/easy_spec.rb",
|
70
|
+
"spec/typhoeus/filter_spec.rb",
|
71
|
+
"spec/typhoeus/multi_spec.rb",
|
72
|
+
"spec/typhoeus/remote_method_spec.rb",
|
73
|
+
"spec/typhoeus/remote_proxy_object_spec.rb",
|
74
|
+
"spec/typhoeus/remote_spec.rb",
|
75
|
+
"spec/typhoeus/response_spec.rb",
|
76
|
+
"examples/twitter.rb"
|
77
|
+
]
|
78
|
+
|
79
|
+
if s.respond_to? :specification_version then
|
80
|
+
current_version = Gem::Specification::CURRENT_SPECIFICATION_VERSION
|
81
|
+
s.specification_version = 3
|
82
|
+
|
83
|
+
if Gem::Version.new(Gem::RubyGemsVersion) >= Gem::Version.new('1.2.0') then
|
84
|
+
else
|
85
|
+
end
|
86
|
+
else
|
87
|
+
end
|
88
|
+
end
|
metadata
ADDED
@@ -0,0 +1,104 @@
|
|
1
|
+
--- !ruby/object:Gem::Specification
|
2
|
+
name: abhay-typhoeus
|
3
|
+
version: !ruby/object:Gem::Version
|
4
|
+
version: 0.0.22
|
5
|
+
platform: ruby
|
6
|
+
authors:
|
7
|
+
- Paul Dix
|
8
|
+
autorequire:
|
9
|
+
bindir: bin
|
10
|
+
cert_chain: []
|
11
|
+
|
12
|
+
date: 2009-08-26 00:00:00 -07:00
|
13
|
+
default_executable:
|
14
|
+
dependencies: []
|
15
|
+
|
16
|
+
description:
|
17
|
+
email: paul@pauldix.net
|
18
|
+
executables: []
|
19
|
+
|
20
|
+
extensions:
|
21
|
+
- ext/typhoeus/extconf.rb
|
22
|
+
extra_rdoc_files: []
|
23
|
+
|
24
|
+
files:
|
25
|
+
- .gitignore
|
26
|
+
- README.textile
|
27
|
+
- Rakefile
|
28
|
+
- VERSION
|
29
|
+
- benchmarks/profile.rb
|
30
|
+
- benchmarks/vs_nethttp.rb
|
31
|
+
- examples/twitter.rb
|
32
|
+
- ext/typhoeus/.gitignore
|
33
|
+
- ext/typhoeus/extconf.rb
|
34
|
+
- ext/typhoeus/native.c
|
35
|
+
- ext/typhoeus/native.h
|
36
|
+
- ext/typhoeus/typhoeus_easy.c
|
37
|
+
- ext/typhoeus/typhoeus_easy.h
|
38
|
+
- ext/typhoeus/typhoeus_multi.c
|
39
|
+
- ext/typhoeus/typhoeus_multi.h
|
40
|
+
- lib/typhoeus.rb
|
41
|
+
- lib/typhoeus/.gitignore
|
42
|
+
- lib/typhoeus/easy.rb
|
43
|
+
- lib/typhoeus/filter.rb
|
44
|
+
- lib/typhoeus/multi.rb
|
45
|
+
- lib/typhoeus/remote.rb
|
46
|
+
- lib/typhoeus/remote_method.rb
|
47
|
+
- lib/typhoeus/remote_proxy_object.rb
|
48
|
+
- lib/typhoeus/response.rb
|
49
|
+
- lib/typhoeus/service.rb
|
50
|
+
- profilers/valgrind.rb
|
51
|
+
- spec/fixtures/result_set.xml
|
52
|
+
- spec/servers/app.rb
|
53
|
+
- spec/servers/delay_fixture_server.rb
|
54
|
+
- spec/servers/method_server.rb
|
55
|
+
- spec/spec.opts
|
56
|
+
- spec/spec_helper.rb
|
57
|
+
- spec/typhoeus/easy_spec.rb
|
58
|
+
- spec/typhoeus/filter_spec.rb
|
59
|
+
- spec/typhoeus/multi_spec.rb
|
60
|
+
- spec/typhoeus/remote_method_spec.rb
|
61
|
+
- spec/typhoeus/remote_proxy_object_spec.rb
|
62
|
+
- spec/typhoeus/remote_spec.rb
|
63
|
+
- spec/typhoeus/response_spec.rb
|
64
|
+
- typhoeus.gemspec
|
65
|
+
has_rdoc: false
|
66
|
+
homepage: http://github.com/pauldix/typhoeus
|
67
|
+
post_install_message:
|
68
|
+
rdoc_options:
|
69
|
+
- --charset=UTF-8
|
70
|
+
require_paths:
|
71
|
+
- - lib
|
72
|
+
- ext
|
73
|
+
required_ruby_version: !ruby/object:Gem::Requirement
|
74
|
+
requirements:
|
75
|
+
- - ">="
|
76
|
+
- !ruby/object:Gem::Version
|
77
|
+
version: "0"
|
78
|
+
version:
|
79
|
+
required_rubygems_version: !ruby/object:Gem::Requirement
|
80
|
+
requirements:
|
81
|
+
- - ">="
|
82
|
+
- !ruby/object:Gem::Version
|
83
|
+
version: "0"
|
84
|
+
version:
|
85
|
+
requirements: []
|
86
|
+
|
87
|
+
rubyforge_project:
|
88
|
+
rubygems_version: 1.2.0
|
89
|
+
signing_key:
|
90
|
+
specification_version: 3
|
91
|
+
summary: A library for interacting with web services (and building SOAs) at blinding speed.
|
92
|
+
test_files:
|
93
|
+
- spec/servers/app.rb
|
94
|
+
- spec/servers/delay_fixture_server.rb
|
95
|
+
- spec/servers/method_server.rb
|
96
|
+
- spec/spec_helper.rb
|
97
|
+
- spec/typhoeus/easy_spec.rb
|
98
|
+
- spec/typhoeus/filter_spec.rb
|
99
|
+
- spec/typhoeus/multi_spec.rb
|
100
|
+
- spec/typhoeus/remote_method_spec.rb
|
101
|
+
- spec/typhoeus/remote_proxy_object_spec.rb
|
102
|
+
- spec/typhoeus/remote_spec.rb
|
103
|
+
- spec/typhoeus/response_spec.rb
|
104
|
+
- examples/twitter.rb
|