Mislav Marohnić
264492a4a8
enable setting per-request options
...
Global request options (`connection.options`) are copied to the env
hash as env[:request]. This adds the ability to customize these options
per request:
conn.get('/') do |req|
req.options[:timeout] = 10
req.options[:proxy] = {:user => 'dave'}
end
Local options are merged recursively with global ones.
2011-06-27 17:29:45 +02:00
Florian Munz
e966cc6e5a
align patron timeout setting with net_http
2011-06-22 20:21:40 +02:00
Mislav Marohnić
91df303b86
Merge pull request #65 from zbelzer/master
...
Implement existing SSL options in Typheous adapter
2011-06-22 10:50:58 -07:00
Florian Munz
51f115d43e
pass timeouts to patron adapter
2011-06-22 15:08:34 +02:00
Zachary Belzer
538a794bdd
Adding SSL options to Typhoeus
...
I tried to stay in the spirit of Net::HTTP in terms of how the options
are set. Typhoeus takes paths to the cert files so I'm considering those
different options (*_file) for ssl that are a complement the ca_file
option already present.
2011-06-21 17:18:49 -05:00
risk
e61e92b9ee
Faraday::Connection#build_url doesnt add an ending slash to urls
2011-06-16 12:23:45 -04:00
risk
2ce28e9a81
Release 0.7.2
v0.7.2
2011-06-12 14:10:29 -07:00
risk
11011acf43
allow setting ssl verify_depth with net/http
2011-06-12 14:10:05 -07:00
Erik Michaels-Ober
354626c80a
Revert "Update activesupport dependency to 3.0"
...
This reverts commit 751d64d9edaff35db78e3f21a43361d2b67f5092.
Active Support 3 is causing tests to break on Ruby 1.8.6.
2011-06-09 10:57:28 -07:00
rick
41c3e49e67
Release 0.7.1
v0.7.1
2011-06-09 09:35:11 -07:00
rick
8519c11e98
fix test stubs so extra get params not specified in the stub path are allowed. also, the parsed query string is available in the yielded stub env so you can test those in the stub block.
2011-06-09 09:28:41 -07:00
Erik Michaels-Ober
8dbca3cc42
Test against Rubinius 2.0
2011-06-08 12:25:07 -04:00
Erik Michaels-Ober
006824f4ed
Merge pull request #61 from steveburkett/master
...
204, 304 must not have a body
2011-05-23 14:36:21 -07:00
Steve Burkett
adcb73704a
remove the xml file
2011-05-23 14:35:26 -07:00
Steve Burkett
179fef4cbc
204, 304 must not have a body
2011-05-23 14:28:23 -07:00
Erik Michaels-Ober
8ae879e4d5
Return true for any 2xx HTTP response status
...
Closes #58 .
2011-05-20 15:02:02 -07:00
Erik Michaels-Ober
ddc5bd7dbe
Link to LICENSE
2011-05-20 11:04:00 -07:00
Erik Michaels-Ober
751d64d9ed
Update activesupport dependency to 3.0
2011-05-20 10:19:34 -07:00
Erik Michaels-Ober
886bb3880f
Update rake dependency to version 0.9
2011-05-20 10:10:12 -07:00
Erik Michaels-Ober
01ba2af1ef
Separate dependency specification in the gemspec from the Gemfile
...
This is probably a bad idea, but it's necessary to get Faraday tests
passing on Ruby 1.8.6, since Rack 1.2.1 and 1.2.2 break on 1.8.6.
Unfortunately, Action Pack 3 depends on rack ~> 1.2.1, so specifying a
version of Rack < 1.2.1 would have prevented the next release of Faraday
from being used with Rails 3.
*Sigh*
2011-05-14 23:45:12 -07:00
Erik Michaels-Ober
faea5fd748
Specify test-unit development dependency
2011-05-14 20:06:51 -07:00
Erik Michaels-Ober
21a92c6eb3
Revert to using leftright
2011-05-14 19:50:33 -07:00
Erik Michaels-Ober
bbfcc2539f
Use turn instead of leftright
2011-05-14 19:33:51 -07:00
Erik Michaels-Ober
706468e70f
Don't use symbol to proc in tests so that they'll run on Ruby 1.8.6
2011-05-14 19:24:23 -07:00
Erik Michaels-Ober
ec7c74442b
Require test/unit after loading bundler
2011-05-14 19:23:43 -07:00
Erik Michaels-Ober
c269074ada
Don't use rack > 1.2.0 due to an incompatibility with Ruby 1.8.6
2011-05-14 19:04:39 -07:00
Erik Michaels-Ober
1360e78019
Revert "removed ruby 1.8.6 from CI due to Rack 1.2.2 not being compatible"
...
This reverts commit 1f0537f7d6526a03778c25272d6d508428a891ee.
2011-05-14 19:02:32 -07:00
Mislav Marohnić
1f0537f7d6
removed ruby 1.8.6 from CI due to Rack 1.2.2 not being compatible
2011-05-13 15:00:07 -07:00
Mislav Marohnić
7f17195482
added "test:live" task to run live tests against faradaylive.heroku.com
2011-05-13 15:00:00 -07:00
Mislav Marohnić
4a9405d216
fixed Patron hack in case the library is not available
2011-05-13 14:56:28 -07:00
Erik Michaels-Ober
9fc7d7e4c1
Add jruby-openssl dependency on java platforms
2011-05-13 14:27:45 -07:00
Mislav Marohnić
ba81f4c243
instuct Travis to run live tests against "faradaylive.heroku.com"
2011-05-13 11:43:29 -07:00
Mislav Marohnić
cd055241bf
avoid empty PUT body test with Typhoeus because of its bug
...
The bug is probably https://github.com/dbalatero/typhoeus/issues/84
2011-05-13 11:42:25 -07:00
Mislav Marohnić
d55a9425c5
add config.ru for running "live_server.rb" on Heroku
2011-05-13 10:53:44 -07:00
Mislav Marohnić
f7e80bf4ce
fix Builder::Handler comparison to another Handler
2011-05-13 10:24:56 -07:00
Erik Michaels-Ober
accd07fa20
Update addressable dependency to version 2.2.6
2011-05-12 19:19:41 -07:00
Erik Michaels-Ober
62a70cee57
Test all Rubies. Let's see what breaks!
2011-05-10 11:23:11 -07:00
Erik Michaels-Ober
d7c23bc2e8
Release 0.7.0
v0.7.0
2011-05-10 11:21:20 -07:00
Erik Michaels-Ober
e778d39935
Bump version to 0.7.0
2011-05-10 11:21:16 -07:00
Erik Michaels-Ober
b9cf9347dc
Merge pull request #55 from mislav/requests
...
Caches middleware stack; refactors Request class
2011-05-09 14:40:46 -07:00
Mislav Marohnić
2343a4e98f
support PATCH and OPTIONS methods
...
Added a `patch` helper method, but OPTIONS requests need to be done manually.
2011-05-09 01:07:32 -07:00
Mislav Marohnić
7fa58f2009
refactor how Requests are ran
...
The Request class is not responsible for running itself anymore.
Its `run` methods (both class and instance) are gone.
The actual running of the request is handled by Connection in the
`run_request` method.
2011-05-08 16:24:13 -07:00
Mislav Marohnić
b47fb2922f
cache middleware stack instead of rebuilding it on every request
...
The downside is, middleware can't be modified after making the first request:
conn.use MyMiddleware # => OK
conn.get('/')
conn.use AnotherMiddleware # => raises a Builder::StackLocked error
On the plus side, the middleware stack is built only once and then cached as
the Connection#app object.
The Connection instance can always be "forked off" with the `dup` method and
modified as if it were fresh.
2011-05-08 14:20:51 -07:00
Mislav Marohnić
9ae912b2c8
refactor query params hash handling
...
- Connection#params is now an instance of Faraday::Utils::ParamsHash
- get rid of `merge_params`, `merge_headers` methods
- don't mix in Faraday::Utils into Connection
Fixes #48
2011-05-07 20:21:31 -07:00
Erik Michaels-Ober
2e24f7005c
Rakefiles are executables, and rake loads rake, not rakefile code
2011-05-06 11:48:52 -07:00
Erik Michaels-Ober
3254837891
Update excon development/test dependency to version ~> 0.6
2011-04-27 13:37:02 -07:00
Erik Michaels-Ober
6411855dce
Release 0.6.1
v0.6.1
2011-04-13 12:26:35 -04:00
Erik Michaels-Ober
539ab74462
Release 0.6.1
2011-04-13 12:26:31 -04:00
Alex Kremer
71c101b0eb
Add ca_path to SSL options hash
2011-04-13 10:31:17 +08:00
Mislav Marohnić
b85e0a18df
refactor how adapters save response params to env
...
Ensures :response_headers always get initialized
Closes #50
2011-04-04 20:06:32 +02:00