rest-client 2.0.1-x86-mingw32 → 2.0.2-x86-mingw32

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 90f816c5864fc8e81f3bc5f06a0e2da8144e241b
4
- data.tar.gz: fe72a7b7c83d3edb8952bf1ca4f3b3afc483018c
3
+ metadata.gz: e42274691118daa3db14a998c6d3f37850312300
4
+ data.tar.gz: 67846732a7926b335a7082eb1fba0b7178f0c5c4
5
5
  SHA512:
6
- metadata.gz: 5cf7e934cf28feca0693463ff753c5dbc34e0d19e6ef7a1200823dce2f4905b3fee8e8a580fc81026ef26acc65108c5a3d1ff4babe369a1ec2e6e106beeb4c76
7
- data.tar.gz: dca326f15f34e580a4c0f40e768e06e8cec878b9936b5dc4eb758940f9e0bbd39bf323532b354d701f472da5aeb00dc40edff690145d612392576c30c0167c59
6
+ metadata.gz: 824004c1bff42cacda66c9ba1027b7e4be99fc43af327458f26ceca6eb01fbc5edb201f825ab1744e6438fb614955227cbd1f08225fe8a4df9763b37ea2d2894
7
+ data.tar.gz: 812f11c8a6c2c4ac5ec68852e75f64ae2d7416ae4683f5ff6525055dbf8e472baed3cc01a85eb76e5da2cb39233ff2dc2129cbdab7165dec89637987b346359b
data/.travis.yml CHANGED
@@ -17,6 +17,8 @@ rvm:
17
17
  - "jruby-9.1.5.0"
18
18
  - "jruby-head"
19
19
 
20
+ cache: bundler
21
+
20
22
  script:
21
23
  bundle exec rake test
22
24
 
@@ -44,10 +46,3 @@ matrix:
44
46
  fast_finish: true
45
47
 
46
48
  sudo: false
47
-
48
-
49
- # Use Java 8 for jruby to fix some Java 7 bugs.
50
- addons:
51
- apt:
52
- packages:
53
- - oracle-java8-set-default
data/README.md CHANGED
@@ -762,13 +762,12 @@ Need caching, more advanced logging or any ability provided by Rack middleware?
762
762
  Have a look at rest-client-components: http://github.com/crohr/rest-client-components
763
763
 
764
764
  ## Credits
765
-
766
- |||
767
- |---------------------|---------------------------------------------------------|
768
- | REST Client Team | Andy Brody |
769
- | Creator | Adam Wiggins |
770
- | Maintainers Emeriti | Lawrence Leonard Gilbert, Matthew Manning, Julien Kirch |
771
- | Major contributions | Blake Mizerany, Julien Kirch |
765
+ | | |
766
+ |-------------------------|---------------------------------------------------------|
767
+ | **REST Client Team** | Andy Brody |
768
+ | **Creator** | Adam Wiggins |
769
+ | **Maintainers Emeriti** | Lawrence Leonard Gilbert, Matthew Manning, Julien Kirch |
770
+ | **Major contributions** | Blake Mizerany, Julien Kirch |
772
771
 
773
772
  A great many generous folks have contributed features and patches.
774
773
  See AUTHORS for the full list.
data/history.md CHANGED
@@ -1,3 +1,8 @@
1
+ # 2.0.2
2
+
3
+ - Suppress the header override warning introduced in 2.0.1 if the value is the
4
+ same. There's no conflict if the value is unchanged. (#578)
5
+
1
6
  # 2.0.1
2
7
 
3
8
  - Warn if auto-generated headers from the payload, such as Content-Type,
@@ -373,7 +373,7 @@ module RestClient
373
373
  # x-www-form-urlencoded but a Content-Type application/json was
374
374
  # also supplied by the user.
375
375
  payload_headers.each_pair do |key, val|
376
- if headers.include?(key)
376
+ if headers.include?(key) && headers[key] != val
377
377
  warn("warning: Overriding #{key.inspect} header " +
378
378
  "#{headers.fetch(key).inspect} with #{val.inspect} " +
379
379
  "due to payload")
@@ -1,5 +1,5 @@
1
1
  module RestClient
2
- VERSION_INFO = [2, 0, 1] unless defined?(self::VERSION_INFO)
2
+ VERSION_INFO = [2, 0, 2] unless defined?(self::VERSION_INFO)
3
3
  VERSION = VERSION_INFO.map(&:to_s).join('.') unless defined?(self::VERSION)
4
4
 
5
5
  def self.version
@@ -13,7 +13,8 @@ describe RestClient::Request do
13
13
  def default_httpbin_url
14
14
  # add a hack to work around java/jruby bug
15
15
  # java.lang.RuntimeException: Could not generate DH keypair with backtrace
16
- if ['jruby-19mode', 'jruby-9.0.5.0'].include?(ENV['TRAVIS_RUBY_VERSION'])
16
+ # Also (2017-04-09) Travis Jruby versions have a broken CA keystore
17
+ if ENV['TRAVIS_RUBY_VERSION'] =~ /\Ajruby-/
17
18
  'http://httpbin.org/'
18
19
  else
19
20
  'https://httpbin.org/'
@@ -280,6 +280,13 @@ describe RestClient::Request, :include_helpers do
280
280
  }).to match(/warning: Overriding "Content-Length" header/i)
281
281
  end
282
282
 
283
+ it "does not warn when overriding user header with header derived from payload if those header values were identical" do
284
+ expect(fake_stderr {
285
+ RestClient::Request.new(method: :post, url: 'example.com',
286
+ payload: {'foo' => '123456'}, headers: { 'Content-Type' => 'application/x-www-form-urlencoded' })
287
+ }).not_to match(/warning: Overriding "Content-Type" header/i)
288
+ end
289
+
283
290
  it 'does not warn for a normal looking payload' do
284
291
  expect(fake_stderr {
285
292
  RestClient::Request.new(method: :post, url: 'example.com', payload: 'payload')
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: rest-client
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.0.1
4
+ version: 2.0.2
5
5
  platform: x86-mingw32
6
6
  authors:
7
7
  - REST Client Team
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2017-02-19 00:00:00.000000000 Z
11
+ date: 2017-04-23 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: webmock
@@ -258,7 +258,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
258
258
  version: '0'
259
259
  requirements: []
260
260
  rubyforge_project:
261
- rubygems_version: 2.5.1
261
+ rubygems_version: 2.6.11
262
262
  signing_key:
263
263
  specification_version: 4
264
264
  summary: Simple HTTP and REST client for Ruby, inspired by microframework syntax for