lhc 3.2.0 → 3.3.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/lhc/request.rb +1 -1
- data/lib/lhc/response.rb +4 -0
- data/lib/lhc/version.rb +1 -1
- data/spec/response/effective_url_spec.rb +16 -0
- metadata +4 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 4bd80d03c65bd862b57ce1124558e137284a3d23
|
4
|
+
data.tar.gz: 4329e5c72edb5119904420d08faaf971190d45e8
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 3129c6d7886946887fb0574d356a405c8e2b5e5f92cafc063582dad73307a62f1d2bc1210e8e570bbe7b22568ac52f1c23392cc88d9e9cb20dbcf3c2eaa2d10b
|
7
|
+
data.tar.gz: 4c484cdc38c4f0efa2b37ab8b455c49fde466d62ed4e69653c2ad3528ec09a1bf0225f4ffb4489ff2ba3bee5c23552fb050b8963e2eda771d56975048b0a55f1
|
data/lib/lhc/request.rb
CHANGED
@@ -7,7 +7,7 @@ require 'active_support/core_ext/object/deep_dup'
|
|
7
7
|
# and it communicates with interceptors.
|
8
8
|
class LHC::Request
|
9
9
|
|
10
|
-
TYPHOEUS_OPTIONS = [:params, :method, :body, :headers]
|
10
|
+
TYPHOEUS_OPTIONS = [:params, :method, :body, :headers, :follow_location]
|
11
11
|
|
12
12
|
attr_accessor :response, :options, :raw
|
13
13
|
|
data/lib/lhc/response.rb
CHANGED
data/lib/lhc/version.rb
CHANGED
@@ -0,0 +1,16 @@
|
|
1
|
+
require 'rails_helper'
|
2
|
+
|
3
|
+
describe LHC::Response do
|
4
|
+
|
5
|
+
context 'effective_url' do
|
6
|
+
|
7
|
+
let(:effective_url) { 'https://www.local.ch' }
|
8
|
+
|
9
|
+
let(:raw_response) { OpenStruct.new(effective_url: effective_url) }
|
10
|
+
|
11
|
+
it 'provides effective_url' do
|
12
|
+
response = LHC::Response.new(raw_response, nil)
|
13
|
+
expect(response.effective_url).to eq effective_url
|
14
|
+
end
|
15
|
+
end
|
16
|
+
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: lhc
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 3.
|
4
|
+
version: 3.3.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- local.ch
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2015-12-
|
11
|
+
date: 2015-12-14 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: typhoeus
|
@@ -218,6 +218,7 @@ files:
|
|
218
218
|
- spec/response/body_spec.rb
|
219
219
|
- spec/response/code_spec.rb
|
220
220
|
- spec/response/data_spec.rb
|
221
|
+
- spec/response/effective_url_spec.rb
|
221
222
|
- spec/response/headers_spec.rb
|
222
223
|
- spec/response/options_spec.rb
|
223
224
|
- spec/response/success_spec.rb
|
@@ -327,6 +328,7 @@ test_files:
|
|
327
328
|
- spec/response/body_spec.rb
|
328
329
|
- spec/response/code_spec.rb
|
329
330
|
- spec/response/data_spec.rb
|
331
|
+
- spec/response/effective_url_spec.rb
|
330
332
|
- spec/response/headers_spec.rb
|
331
333
|
- spec/response/options_spec.rb
|
332
334
|
- spec/response/success_spec.rb
|