wavefront-sdk 3.5.0 → 3.6.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/HISTORY.md +4 -0
- data/lib/wavefront-sdk/defs/version.rb +1 -1
- data/lib/wavefront-sdk/user.rb +10 -0
- data/spec/wavefront-sdk/user_spec.rb +8 -0
- data/wavefront-sdk.gemspec +2 -2
- metadata +6 -6
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: cebe33cf2ebe1428fe26352575f9271d951d42d1e8ba171ae20636da3295b342
|
4
|
+
data.tar.gz: 566fc5988025e8bc3db50c7df0d4dd4cf3578b2a9156ef6cb605e4882553e6b7
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 6cdc071dc6f152192e565dec067ddd756a055b5b976dc4a1a76ef254e4eae08577419662ba8411926fc2639b6280210223ba3674e0ea4097063e8ced46af1245
|
7
|
+
data.tar.gz: 85b7b0a209643379af464c8a9c1b5bf465374712ed23b148ae7a4a7c7a23ffc7535e1cef32e83e7a33dae47100ab00eaaa5aced4f5781dd14a224f97d43cbb0b
|
data/HISTORY.md
CHANGED
data/lib/wavefront-sdk/user.rb
CHANGED
@@ -202,6 +202,16 @@ module Wavefront
|
|
202
202
|
api.post('invite', body, 'application/json')
|
203
203
|
end
|
204
204
|
|
205
|
+
# GET /api/v2/user/{id}/businessFunctions
|
206
|
+
# Returns business functions of a specific user.
|
207
|
+
# @param id [String] user ID
|
208
|
+
# @return [Wavefront::Response]
|
209
|
+
#
|
210
|
+
def business_functions(id)
|
211
|
+
wf_user_id?(id)
|
212
|
+
api.get([id, 'businessFunctions'].uri_concat)
|
213
|
+
end
|
214
|
+
|
205
215
|
# Fake a response which looks like we get from all the other
|
206
216
|
# paths. I'm expecting the user response model to be made
|
207
217
|
# consistent with others in the future.
|
@@ -102,6 +102,14 @@ class WavefrontUserTest < WavefrontTestBase
|
|
102
102
|
assert_raises(ArgumentError) { wf.invite('test') }
|
103
103
|
end
|
104
104
|
|
105
|
+
def test_business_functions
|
106
|
+
assert_gets("/api/v2/user/#{id}/businessFunctions") do
|
107
|
+
wf.business_functions(id)
|
108
|
+
end
|
109
|
+
|
110
|
+
assert_raises(ArgumentError) { wf.business_functions }
|
111
|
+
end
|
112
|
+
|
105
113
|
def test_response_shim
|
106
114
|
(RESOURCE_DIR + 'user_responses').each_child do |input|
|
107
115
|
# Ugly hack for the 202 in the 'create' file
|
data/wavefront-sdk.gemspec
CHANGED
@@ -23,13 +23,13 @@ Gem::Specification.new do |gem|
|
|
23
23
|
gem.bindir = 'bin'
|
24
24
|
|
25
25
|
gem.add_dependency 'addressable', '~> 2.7'
|
26
|
-
gem.add_dependency 'faraday', '~> 0.
|
26
|
+
gem.add_dependency 'faraday', '~> 0.17.0'
|
27
27
|
gem.add_dependency 'inifile', '~> 3.0'
|
28
28
|
gem.add_dependency 'map', '~> 6.6'
|
29
29
|
|
30
30
|
gem.add_development_dependency 'minitest', '~> 5.11'
|
31
31
|
gem.add_development_dependency 'rake', '~> 12.3'
|
32
|
-
gem.add_development_dependency 'rubocop', '~> 0.
|
32
|
+
gem.add_development_dependency 'rubocop', '~> 0.76'
|
33
33
|
gem.add_development_dependency 'simplecov', '~> 0.16'
|
34
34
|
gem.add_development_dependency 'spy', '~> 1.0.0'
|
35
35
|
gem.add_development_dependency 'webmock', '~> 3.7'
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: wavefront-sdk
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 3.
|
4
|
+
version: 3.6.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Robert Fisher
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2019-
|
11
|
+
date: 2019-11-12 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: addressable
|
@@ -30,14 +30,14 @@ dependencies:
|
|
30
30
|
requirements:
|
31
31
|
- - "~>"
|
32
32
|
- !ruby/object:Gem::Version
|
33
|
-
version: 0.
|
33
|
+
version: 0.17.0
|
34
34
|
type: :runtime
|
35
35
|
prerelease: false
|
36
36
|
version_requirements: !ruby/object:Gem::Requirement
|
37
37
|
requirements:
|
38
38
|
- - "~>"
|
39
39
|
- !ruby/object:Gem::Version
|
40
|
-
version: 0.
|
40
|
+
version: 0.17.0
|
41
41
|
- !ruby/object:Gem::Dependency
|
42
42
|
name: inifile
|
43
43
|
requirement: !ruby/object:Gem::Requirement
|
@@ -100,14 +100,14 @@ dependencies:
|
|
100
100
|
requirements:
|
101
101
|
- - "~>"
|
102
102
|
- !ruby/object:Gem::Version
|
103
|
-
version: '0.
|
103
|
+
version: '0.76'
|
104
104
|
type: :development
|
105
105
|
prerelease: false
|
106
106
|
version_requirements: !ruby/object:Gem::Requirement
|
107
107
|
requirements:
|
108
108
|
- - "~>"
|
109
109
|
- !ruby/object:Gem::Version
|
110
|
-
version: '0.
|
110
|
+
version: '0.76'
|
111
111
|
- !ruby/object:Gem::Dependency
|
112
112
|
name: simplecov
|
113
113
|
requirement: !ruby/object:Gem::Requirement
|