avocado-docs 3.0.5 → 3.0.6

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: fe69bcb64be7f56846b8e1cbff51f304c7b9e9df
4
- data.tar.gz: 3e8283188a6e4b77f8f41e01f7c95220b243a875
3
+ metadata.gz: 0c9803affe7df740b852677f01fd979b84ee9417
4
+ data.tar.gz: b932d3d2b21c554b6bd77fcf6652770693cf4ef7
5
5
  SHA512:
6
- metadata.gz: 4427bcffdbf4f24dbdc04c14e3f64a15c41d56924dfc492f9ce853c65cd1e8a0ff0270ce62db684dd121190df757044151136714282a4078dbc8b85c33ff8d10
7
- data.tar.gz: 66f45c7ea2bb685ef786c24f15cfa052a214445d8d2767e740484f7f3d38b124543ab3737cb9ccc76baad5e67aa3ea0855b4d3897d58499bc728c4cf52612f00
6
+ metadata.gz: efed4c0097e8d7576b1bee23328f86fcbfc8f9e281e2874633dd0db10a91789980db6659553897351b1098833884eea17b84c9a42c2c328761aa80259e927873
7
+ data.tar.gz: 95e5dd275e6343fb90fbde09ccc3dc1b7841fe9fd9ece68f8b985653f90f0f0e05d2a53a78ce19db85f4bd935cfe0bb0a3f350efd046541c536753c9dca180a6
@@ -16,6 +16,16 @@ module Avocado
16
16
  net_request = Net::HTTP.new(uri.host, uri.port)
17
17
  net_request.use_ssl = (uri.scheme == 'https')
18
18
  net_request.start { |http| http.request(request) }
19
+
20
+ case response
21
+ when Net::HTTPSuccess then
22
+ response
23
+ when Net::HTTPRedirection then
24
+ location = response['location']
25
+ raise "Avocado was redirected to '#{location}', update your initializer!"
26
+ else
27
+ raise response.value
28
+ end
19
29
  end
20
30
  ensure
21
31
  WebMock.disable_net_connect! if defined? WebMock
@@ -1,3 +1,3 @@
1
1
  module Avocado
2
- VERSION = '3.0.5'
2
+ VERSION = '3.0.6'
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: avocado-docs
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.0.5
4
+ version: 3.0.6
5
5
  platform: ruby
6
6
  authors:
7
7
  - Logan Serman