bearcat 1.3.11 → 1.3.12
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:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: b5b5f7a9d11d99b46ef1b1965c3b6afd82431522
|
4
|
+
data.tar.gz: fd23d4e219b7e0d4e63a80f693c499e15e3db0de
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 0b7f07d44fd47770f1d5fd058c1f6446294e850b82ddc3c08cec85c8232eceb731ec7dc950b99977d730cd161e82262fdd00110928985bb2e89b2a12107f68f1
|
7
|
+
data.tar.gz: a5c8ed68c528143779983985dab5e05b5ed751566415e33ca18ac5408ab74970aff95640e91348f48bb98c8707f38b40f48dcdc20521a1139f509ddc42d7ee44
|
@@ -2,6 +2,10 @@ module Bearcat
|
|
2
2
|
class Client < Footrest::Client
|
3
3
|
module GroupMemberships
|
4
4
|
|
5
|
+
def group_membership(group, group_membership)
|
6
|
+
get("/api/v1/groups/#{group}/memberships/#{group_membership}")
|
7
|
+
end
|
8
|
+
|
5
9
|
def list_group_memberships(group)
|
6
10
|
get("/api/v1/groups/#{group.to_s}/memberships")
|
7
11
|
end
|
@@ -15,4 +19,4 @@ module Bearcat
|
|
15
19
|
end
|
16
20
|
end
|
17
21
|
end
|
18
|
-
end
|
22
|
+
end
|
data/lib/bearcat/version.rb
CHANGED
@@ -0,0 +1,14 @@
|
|
1
|
+
require 'helper'
|
2
|
+
|
3
|
+
describe Bearcat::Client::GroupMemberships do
|
4
|
+
before do
|
5
|
+
@client = Bearcat::Client.new(prefix: "http://canvas.instructure.com", token: "test_token")
|
6
|
+
end
|
7
|
+
|
8
|
+
it 'gets a single group membership' do
|
9
|
+
stub_get(@client, "/api/v1/groups/1/memberships/1").to_return(json_response('group_membership.json'))
|
10
|
+
group_membership = @client.group_membership(1, 1)
|
11
|
+
group_membership['user_id'].should == 26906
|
12
|
+
end
|
13
|
+
|
14
|
+
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: bearcat
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.3.
|
4
|
+
version: 1.3.12
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Nathan Mills, Jake Sorce
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2017-03-
|
11
|
+
date: 2017-03-15 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rake
|
@@ -158,6 +158,7 @@ files:
|
|
158
158
|
- spec/bearcat/client/files_spec.rb
|
159
159
|
- spec/bearcat/client/folders_spec.rb
|
160
160
|
- spec/bearcat/client/group_categories_spec.rb
|
161
|
+
- spec/bearcat/client/group_membership_spec.rb
|
161
162
|
- spec/bearcat/client/groups_spec.rb
|
162
163
|
- spec/bearcat/client/module_items_spec.rb
|
163
164
|
- spec/bearcat/client/modules_spec.rb
|
@@ -255,6 +256,7 @@ files:
|
|
255
256
|
- spec/fixtures/group_category.json
|
256
257
|
- spec/fixtures/group_category_groups.json
|
257
258
|
- spec/fixtures/group_conferences.json
|
259
|
+
- spec/fixtures/group_membership.json
|
258
260
|
- spec/fixtures/link_unlink_outcome.json
|
259
261
|
- spec/fixtures/merge_user.json
|
260
262
|
- spec/fixtures/module_item_sequence.json
|
@@ -314,7 +316,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
314
316
|
version: '0'
|
315
317
|
requirements: []
|
316
318
|
rubyforge_project:
|
317
|
-
rubygems_version: 2.4.
|
319
|
+
rubygems_version: 2.4.8
|
318
320
|
signing_key:
|
319
321
|
specification_version: 4
|
320
322
|
summary: Canvas API
|
@@ -337,6 +339,7 @@ test_files:
|
|
337
339
|
- spec/bearcat/client/files_spec.rb
|
338
340
|
- spec/bearcat/client/folders_spec.rb
|
339
341
|
- spec/bearcat/client/group_categories_spec.rb
|
342
|
+
- spec/bearcat/client/group_membership_spec.rb
|
340
343
|
- spec/bearcat/client/groups_spec.rb
|
341
344
|
- spec/bearcat/client/module_items_spec.rb
|
342
345
|
- spec/bearcat/client/modules_spec.rb
|
@@ -434,6 +437,7 @@ test_files:
|
|
434
437
|
- spec/fixtures/group_category.json
|
435
438
|
- spec/fixtures/group_category_groups.json
|
436
439
|
- spec/fixtures/group_conferences.json
|
440
|
+
- spec/fixtures/group_membership.json
|
437
441
|
- spec/fixtures/link_unlink_outcome.json
|
438
442
|
- spec/fixtures/merge_user.json
|
439
443
|
- spec/fixtures/module_item_sequence.json
|
@@ -474,4 +478,3 @@ test_files:
|
|
474
478
|
- spec/fixtures/user_page_views.json
|
475
479
|
- spec/fixtures/user_profile.json
|
476
480
|
- spec/helper.rb
|
477
|
-
has_rdoc:
|