cobot_client 2.1.0 → 3.0.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.travis.yml +1 -0
- data/CHANGELOG.md +3 -0
- data/cobot_client.gemspec +1 -1
- data/lib/cobot_client/version.rb +1 -1
- data/spec/cobot_client/api_client_spec.rb +4 -4
- metadata +5 -4
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 385453cc971469ee0aa77b629caad121b0bac713
|
4
|
+
data.tar.gz: 3bdf837bdbf70114b6388de7de4964acdf118113
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 011aa0946233946fa5d88f9b797220baee3062cc072d672ffd00a775e54d5d8f00cae22fc14bda213a65f5ee8d5cb6111da4e415c18cb93f382201915ab08400
|
7
|
+
data.tar.gz: c11c2109aa6162dc63d5e2e75e585c64640c0c94949348bcf6f90315882143d32a55df751eceb815b928124781cc51661523259ec49688126e930151f0a4f1d9
|
data/.travis.yml
CHANGED
data/CHANGELOG.md
ADDED
data/cobot_client.gemspec
CHANGED
@@ -18,7 +18,7 @@ Gem::Specification.new do |gem|
|
|
18
18
|
|
19
19
|
gem.add_dependency 'virtus', '~>1.0'
|
20
20
|
gem.add_dependency 'oauth2', '~>1.0'
|
21
|
-
gem.add_dependency 'rest-client', '~>1
|
21
|
+
gem.add_dependency 'rest-client', '~>2.0.1'
|
22
22
|
gem.add_dependency 'json', '~>2.0'
|
23
23
|
gem.add_development_dependency 'rspec', '~>3.0'
|
24
24
|
gem.add_development_dependency 'rake', '~>10.0'
|
data/lib/cobot_client/version.rb
CHANGED
@@ -245,11 +245,11 @@ describe CobotClient::ApiClient do
|
|
245
245
|
end
|
246
246
|
|
247
247
|
it 'converts a rest-client error into a cobot error' do
|
248
|
-
allow(RestClient).to receive(:get).and_raise(RestClient::
|
248
|
+
allow(RestClient).to receive(:get).and_raise(RestClient::NotFound)
|
249
249
|
|
250
250
|
expect do
|
251
251
|
api_client.get('co-up', '/invoices')
|
252
|
-
end.to raise_error(CobotClient::
|
252
|
+
end.to raise_error(CobotClient::NotFound)
|
253
253
|
end
|
254
254
|
|
255
255
|
it 'retries a RestClient::RequestTimeout' do
|
@@ -278,12 +278,12 @@ describe CobotClient::ApiClient do
|
|
278
278
|
|
279
279
|
it 'includes the response, http code and http body in the exception' do
|
280
280
|
response = double(:response, code: 404, body: 'boom')
|
281
|
-
error = RestClient::
|
281
|
+
error = RestClient::NotFound.new(response)
|
282
282
|
allow(RestClient).to receive(:get).and_raise(error)
|
283
283
|
|
284
284
|
begin
|
285
285
|
api_client.get('co-up', '/invoices')
|
286
|
-
rescue CobotClient::
|
286
|
+
rescue CobotClient::NotFound => e
|
287
287
|
expect(e.response).to eql(response)
|
288
288
|
expect(e.http_code).to eql(404)
|
289
289
|
expect(e.http_body).to eql('boom')
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: cobot_client
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version:
|
4
|
+
version: 3.0.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Alexander Lang
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2018-01-
|
11
|
+
date: 2018-01-17 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: virtus
|
@@ -44,14 +44,14 @@ dependencies:
|
|
44
44
|
requirements:
|
45
45
|
- - "~>"
|
46
46
|
- !ruby/object:Gem::Version
|
47
|
-
version:
|
47
|
+
version: 2.0.1
|
48
48
|
type: :runtime
|
49
49
|
prerelease: false
|
50
50
|
version_requirements: !ruby/object:Gem::Requirement
|
51
51
|
requirements:
|
52
52
|
- - "~>"
|
53
53
|
- !ruby/object:Gem::Version
|
54
|
-
version:
|
54
|
+
version: 2.0.1
|
55
55
|
- !ruby/object:Gem::Dependency
|
56
56
|
name: json
|
57
57
|
requirement: !ruby/object:Gem::Requirement
|
@@ -103,6 +103,7 @@ extra_rdoc_files: []
|
|
103
103
|
files:
|
104
104
|
- ".gitignore"
|
105
105
|
- ".travis.yml"
|
106
|
+
- CHANGELOG.md
|
106
107
|
- Gemfile
|
107
108
|
- LICENSE
|
108
109
|
- README.md
|