726 Commits

Author SHA1 Message Date
Mislav Marohnić
7a38f177dc fix net-http-persistent timeout detection on Ruby 2.0
Re-enable timeout test because drbrain/net-http-persistent#33 got fixed
in net-http-persistent 2.8
2013-04-02 21:41:58 +02:00
Ørjan Blom
c5006e8d88 fix outdated documentation in the Readme
* Link to the new Travis CI build URL.
* Add MRI 2.0.0 to the list of supported and tested versions.
2013-04-01 15:25:59 +02:00
Erik Michaels-Ober
c395b0c463 Merge pull request #250 from leocassarani/keymap-mutex
Fix race conditions in Faraday::Utils::Headers
2013-04-01 04:06:30 -07:00
Leo Cassarani
69096c0f1a Fix race conditions in Faraday::Utils::Headers
Faraday::Utils::Headers uses a shared 'KeyMap' hash to cache
symbol -> string mappings of HTTP header names. When multiple threads
are writing to the cache, race conditions may occur, as the Hash class
is not thread-safe in Ruby.

This commit adds a mutex to synchronize writes to the KeyMap hash.
2013-04-01 02:04:16 +01:00
Joe Pym
ca8c169072 fix escaping Unicode characters in Ruby 1.8.7
In Ruby 1.8, when you are operating with unicode encoding, \w includes
UTF-8 characters such as ☃. Faraday therefore does not escape these
correctly.

Closes #245
2013-03-24 18:07:11 +01:00
Erik Michaels-Ober
36379e01af Add Coveralls for code coverage reporting 2013-02-25 11:30:46 -08:00
Mislav Marohnić
e9164b9bfe Merge branch 'ruby2-compat' 2013-02-25 03:03:32 +01:00
Mislav Marohnić
28653690c6 fix copy_stream test for Rubinius and JRuby 2013-02-25 03:02:46 +01:00
Mislav Marohnić
89af3915f7 include em-synchrony in Ruby 2.0 2013-02-25 03:02:46 +01:00
Mislav Marohnić
f619a5d334 fix file uploads with Ruby 2.0 net/http
Rewrite Faraday::CompositeReadIO because the one inherited from
multipart-post library doesn't behave well when used with
IO.copy_stream which net/http uses internally in Ruby 2.0.
2013-02-25 03:02:45 +01:00
Mislav Marohnić
8775c07495 stop tolerating Ruby 2.0 failures on Travis CI 2013-02-25 03:02:45 +01:00
Mislav Marohnić
ebbf413b36 skip Typhoeus cert test in non-SSL mode 2013-02-25 02:37:05 +01:00
rick
f6831b53b3 set a default user agent 2013-02-17 14:51:13 -07:00
rick
970ab0c5be Merge branch 'typhoeus_ssl_verify' of git://github.com/trptcolin/faraday into trptcolin-typhoeus_ssl_verify 2013-02-17 10:02:31 -07:00
Erik Michaels-Ober
75ab43c2ea Move development dependencies into Gemfile 2013-02-14 09:11:28 -08:00
Erik Michaels-Ober
40481b49f7 Update copyright year [ci skip] 2013-02-09 08:11:14 -08:00
Erik Michaels-Ober
a6059bb5af Use relative links [ci skip] 2013-02-09 07:48:24 -08:00
Erik Michaels-Ober
4ff67eae74 Reword [ci skip] 2013-02-09 07:40:10 -08:00
Erik Michaels-Ober
e156a0d6f3 Use of custom objects is not necessary here 2013-02-03 01:47:05 -08:00
Erik Michaels-Ober
31e7fae0bd Test against Ruby 2.0.0 2013-01-26 00:25:59 -08:00
Colin Jones
4f37e8c0ef Add test to prove rejection of invalid peer 2013-01-16 15:25:42 -06:00
Colin Jones
8f6a14685f Don't VERIFY_NONE when VERIFY_PEER is requested
Looks like a5e9485d inverted the logic on this.
2013-01-15 17:12:31 -06:00
Erik Michaels-Ober
0819790251 Don't redefine constants if they're already defined
Closes #233.
2013-01-10 11:22:55 -08:00
rick
b9e89c7562 Merge pull request #231 from lucasmazza/struct-members
Convert Env keys to symbols
2013-01-08 05:44:42 -08:00
Lucas Mazza
abccadd2be Convert Env keys to symbols 2013-01-07 22:57:40 -02:00
technoweenie
d5afe2b4c0 releasing pushes to legacy remote 2013-01-05 14:37:03 -07:00
technoweenie
7d581322b1 remove some duplication from faraday.gemspec. add scripts 2013-01-05 14:36:32 -07:00
technoweenie
c99350905d faraday/autoload requires faraday 2013-01-05 11:30:00 -07:00
technoweenie
2793e2ae91 ok rbx handles NameError differently 2013-01-05 11:12:31 -07:00
technoweenie
df484dfd1a match against ActiveSupport anywhere in the error name 2013-01-05 11:06:20 -07:00
rick
f978e771b5 Merge pull request #228 from lostisland/instrumentation
add instrumentation middleware.
2013-01-05 10:04:02 -08:00
technoweenie
4b30bf8b5e add instrumentation middleware. original work by @mislav
https://github.com/pengwynn/faraday_middleware/commit/23d5e614eea4f48dd5
a0eee68eb8b3d5e65b5275
2013-01-05 10:41:02 -07:00
Brian D. Burns
5d6faf7671 use Utils.normalize_path() for Stubs 2012-12-31 16:28:10 -07:00
Brian D. Burns
a27c952f5e move Connection.URI to Utils 2012-12-31 16:28:02 -07:00
Brian D. Burns
f24b1b373f handled in superclass 2012-12-31 16:26:20 -07:00
technoweenie
cc27ff9fb4 add Faraday::Builder warning 2012-12-30 11:47:48 -07:00
technoweenie
c17a3c6adb update readme with proxy docs 2012-12-30 11:41:53 -07:00
technoweenie
e63f490693 more ProxyOptions tests 2012-12-30 11:35:16 -07:00
technoweenie
ac1d9e4f36 Option method access 2012-12-30 11:27:30 -07:00
technoweenie
03504db53b allow you to set RequestOptions#proxy 2012-12-30 11:26:35 -07:00
technoweenie
aa8b420739 better Options inspect message 2012-12-30 11:19:49 -07:00
rick
c482e11ab2 Merge pull request #225 from technoweenie/scripts2
improve scripts: done in shell, simpler, no gemspec gen
2012-12-28 11:10:12 -08:00
technoweenie
b38bc47b72 fix a few cases where the configured params encoder was not being used 2012-12-28 09:28:58 -07:00
technoweenie
b035bcb990 make NestedParamsEncoder the default in 0.9 2012-12-28 09:24:42 -07:00
technoweenie
af73cdddc5 revert back to FlatParamsEncoder as the default, but make it customizable 2012-12-28 08:43:36 -07:00
Mislav Marohnić
86c43e5b83 improve scripts: done in shell, simpler, no gemspec gen 2012-12-28 15:55:24 +01:00
Mislav Marohnić
26e9869f0b fix test runner after move to minitest
`testrb` utility is gone from minitest. `autorun` is needed if you want
the test to actually run
2012-12-28 15:53:27 +01:00
technoweenie
0431614bfe require monitor lazily 2012-12-28 02:06:46 -07:00
technoweenie
7e57b5eb2b lets try a monitor instead of a mutex 2012-12-28 02:01:54 -07:00
rick
b25adc0ca6 Merge pull request #224 from technoweenie/fix-ci
Fix CI
2012-12-28 00:51:01 -08:00