onfido 2.0.1 → 2.0.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +4 -0
- data/lib/onfido/resource.rb +3 -0
- data/lib/onfido/version.rb +1 -1
- data/spec/integrations/resource_spec.rb +13 -0
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 7983a2913b8ae4c7a1e53d92b8b62028b57e6e05705f6e5cef13028e77d7a30d
|
4
|
+
data.tar.gz: e923fe60b61214229d3546868a82128607147fb462a7966552ebc67e5d1263e8
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 2ab79a44f5d86fbb3fd17c56e3d876ce256f95f88508300d571ebd6a068973323082f7c1a32cf1edd44bbcec5351a073363c08d4950cae6e0510e54263cff448
|
7
|
+
data.tar.gz: a02418a2e5db122bf0fcf3bce2d5547033e4c8e71b18f7a39006674e0a55cd46fb658986224c6f025c3b028e8bac48d19370c903abaa41e874456420ab2c0bf2
|
data/CHANGELOG.md
CHANGED
data/lib/onfido/resource.rb
CHANGED
@@ -113,6 +113,9 @@ module Onfido
|
|
113
113
|
"Could not verify Onfido's SSL certificate. Please make sure " \
|
114
114
|
'that your network is not intercepting certificates. '
|
115
115
|
|
116
|
+
when RestClient::BadGateway
|
117
|
+
"Could not connect to Onfido. Server may be overloaded." \
|
118
|
+
|
116
119
|
when SocketError
|
117
120
|
'Unexpected error when trying to connect to Onfido. ' \
|
118
121
|
'You may be seeing this message because your DNS is not working. ' \
|
data/lib/onfido/version.rb
CHANGED
@@ -51,6 +51,19 @@ describe Onfido::Resource do
|
|
51
51
|
end
|
52
52
|
end
|
53
53
|
|
54
|
+
context 'RestClient : BadGateway' do
|
55
|
+
before do
|
56
|
+
allow(RestClient::Request)
|
57
|
+
.to receive(:execute)
|
58
|
+
.and_raise(RestClient::BadGateway)
|
59
|
+
end
|
60
|
+
|
61
|
+
it 'raises a ConnectionError' do
|
62
|
+
expect { resource.get(path: '') }
|
63
|
+
.to raise_error(Onfido::ConnectionError, /Could not connect/)
|
64
|
+
end
|
65
|
+
end
|
66
|
+
|
54
67
|
context 'broken connection' do
|
55
68
|
before do
|
56
69
|
allow(RestClient::Request)
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: onfido
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.0.
|
4
|
+
version: 2.0.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Onfido
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2021-
|
11
|
+
date: 2021-06-10 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rspec
|