rest-client 2.0.1-x64-mingw32 → 2.0.2-x64-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: 336963dd7ad8f01ecb2db694d8234fccb14704ee
4
- data.tar.gz: fe72a7b7c83d3edb8952bf1ca4f3b3afc483018c
3
+ metadata.gz: b1dd902b7b9192a3c25ca8a236205d301a80ac44
4
+ data.tar.gz: e7296cd34437dea6f54165815d50b9841cad7bd3
5
5
  SHA512:
6
- metadata.gz: cee9ce148066833e9d8c5693729405bf1687a7941d8d16e9485426010d6dc27d52b99b19a60a3c82ce5d4cec022460ac1a0bdfc6319947b0bc9c0428434844b9
7
- data.tar.gz: dca326f15f34e580a4c0f40e768e06e8cec878b9936b5dc4eb758940f9e0bbd39bf323532b354d701f472da5aeb00dc40edff690145d612392576c30c0167c59
6
+ metadata.gz: 8b06545aab7079f8d44cd1a6118ee3f7a672517fe3f9806d2e2ed968b043a31fc274a19cb0bb73a87bedc4f09415a526b79b0bb54ee9e14ebdbd0172ce601360
7
+ data.tar.gz: 36141eadf551b012f25fb69f0fab9ce2fc50085ad9d6c87f8951fd2fcdb926e350e17acea5910868f5227aef716cde8c782eab7fd0f797a8ad46e82b54e7aab5
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: x64-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