bearcat 1.0.14 → 1.0.15

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: ca811650c1ee4f7aed39e96aa9ba95ea0f4a6568
4
- data.tar.gz: abc0e3425e4d2ced526565757c474d6817b17267
3
+ metadata.gz: 8118abcd2814127909a8a55240160b066e5f2b3a
4
+ data.tar.gz: ce827deeaee4b821fe3c5c5f22e4222d5b16bf6a
5
5
  SHA512:
6
- metadata.gz: 3a0b2b9d1ba47c482ea51515182b176e5875e01907641a4ca83b669e10f70a516be86c9b88353e9b313cc7c89b58f69bfca7a03e0453e6e5fcade9c3b49692d7
7
- data.tar.gz: 6b600db642f6f79c858a57041f67a2bab46150ebe37b7d8c19e82a810c8f4eb8f08f38e22034453c90bca42af403c2467a84b2ee98e1d327118271ce3f3d2d4d
6
+ metadata.gz: 7b7950bf8399b5ca89e338ea1e35756af56076658e50d2bd38f050eb2d2782acb7780dbe73ac8873128fc217264f756b0549973fa95d6ed0abacf5683b11b7e4
7
+ data.tar.gz: 4c8c79251d7dd11adc151f7cb7fcefd086c858cc5224e2c420663d57a131070b3334aaaabc86ec05ac4b6b12f58ee0e0a4d6da753ee886acf77aeb4a1d198c8c
@@ -6,6 +6,10 @@ module Bearcat
6
6
  get("/api/v1/courses/#{course}/assignments", params)
7
7
  end
8
8
 
9
+ def assignment(course, assignment, params={})
10
+ get("/api/v1/courses/#{course}/assignments/#{assignment}", params)
11
+ end
12
+
9
13
  def create_assignment_override(course, assignment, params)
10
14
  post("api/v1/courses/#{course}/assignments/#{assignment}/overrides", params)
11
15
  end
@@ -1,3 +1,3 @@
1
1
  module Bearcat
2
- VERSION = '1.0.14' unless defined?(Bearcat::VERSION)
2
+ VERSION = '1.0.15' unless defined?(Bearcat::VERSION)
3
3
  end
@@ -14,6 +14,14 @@ describe Bearcat::Client::Assignments do
14
14
  assignments.first["due_at"].should == nil
15
15
  end
16
16
 
17
+ it "returns an individual assignment for a course" do
18
+ stub_get(@client, "/api/v1/courses/3/assignments/1").to_return(json_response("assignment.json"))
19
+ assignment = @client.assignment(3, 1)
20
+ assignment["assignment_group_id"].should == 53
21
+ assignment["id"].should == 1
22
+ assignment["due_at"].should == nil
23
+ end
24
+
17
25
  it "creates an assignment override for a section" do
18
26
  stub_post(@client, "/api/v1/courses/310/assignments/123/overrides")
19
27
  .with(:body => {"assignment_override"=>{"course_section_id"=>"74", "due_at"=>"2013-06-27T21:08:46Z"}})
@@ -0,0 +1,32 @@
1
+ {
2
+ "assignment_group_id": 53,
3
+ "automatic_peer_reviews": false,
4
+ "description": "",
5
+ "due_at": null,
6
+ "grade_group_students_individually": false,
7
+ "grading_standard_id": null,
8
+ "grading_type": "points",
9
+ "group_category_id": null,
10
+ "id": 1,
11
+ "lock_at": null,
12
+ "peer_reviews": false,
13
+ "points_possible": 0,
14
+ "position": 14,
15
+ "unlock_at": null,
16
+ "course_id": 3,
17
+ "name": "Start",
18
+ "submission_types": [
19
+ "external_tool"
20
+ ],
21
+ "turnitin_enabled": false,
22
+ "turnitin_settings": {
23
+ "originality_report_visibility": "immediate",
24
+ "s_paper_check": true,
25
+ "internet_check": true,
26
+ "journal_check": true,
27
+ "exclude_biblio": true,
28
+ "exclude_quoted": true,
29
+ "exclude_small_matches_type": null,
30
+ "exclude_small_matches_value": null
31
+ }
32
+ }
metadata CHANGED
@@ -1,97 +1,97 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: bearcat
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.14
4
+ version: 1.0.15
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: 2015-05-05 00:00:00.000000000 Z
11
+ date: 2015-05-19 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rake
15
15
  requirement: !ruby/object:Gem::Requirement
16
16
  requirements:
17
- - - '>='
17
+ - - ">="
18
18
  - !ruby/object:Gem::Version
19
19
  version: '0'
20
20
  type: :development
21
21
  prerelease: false
22
22
  version_requirements: !ruby/object:Gem::Requirement
23
23
  requirements:
24
- - - '>='
24
+ - - ">="
25
25
  - !ruby/object:Gem::Version
26
26
  version: '0'
27
27
  - !ruby/object:Gem::Dependency
28
28
  name: bundler
29
29
  requirement: !ruby/object:Gem::Requirement
30
30
  requirements:
31
- - - '>='
31
+ - - ">="
32
32
  - !ruby/object:Gem::Version
33
33
  version: 1.0.0
34
34
  type: :development
35
35
  prerelease: false
36
36
  version_requirements: !ruby/object:Gem::Requirement
37
37
  requirements:
38
- - - '>='
38
+ - - ">="
39
39
  - !ruby/object:Gem::Version
40
40
  version: 1.0.0
41
41
  - !ruby/object:Gem::Dependency
42
42
  name: rspec
43
43
  requirement: !ruby/object:Gem::Requirement
44
44
  requirements:
45
- - - ~>
45
+ - - "~>"
46
46
  - !ruby/object:Gem::Version
47
47
  version: '2.6'
48
48
  type: :development
49
49
  prerelease: false
50
50
  version_requirements: !ruby/object:Gem::Requirement
51
51
  requirements:
52
- - - ~>
52
+ - - "~>"
53
53
  - !ruby/object:Gem::Version
54
54
  version: '2.6'
55
55
  - !ruby/object:Gem::Dependency
56
56
  name: webmock
57
57
  requirement: !ruby/object:Gem::Requirement
58
58
  requirements:
59
- - - '>='
59
+ - - ">="
60
60
  - !ruby/object:Gem::Version
61
61
  version: '0'
62
62
  type: :development
63
63
  prerelease: false
64
64
  version_requirements: !ruby/object:Gem::Requirement
65
65
  requirements:
66
- - - '>='
66
+ - - ">="
67
67
  - !ruby/object:Gem::Version
68
68
  version: '0'
69
69
  - !ruby/object:Gem::Dependency
70
70
  name: pry
71
71
  requirement: !ruby/object:Gem::Requirement
72
72
  requirements:
73
- - - '>='
73
+ - - ">="
74
74
  - !ruby/object:Gem::Version
75
75
  version: '0'
76
76
  type: :development
77
77
  prerelease: false
78
78
  version_requirements: !ruby/object:Gem::Requirement
79
79
  requirements:
80
- - - '>='
80
+ - - ">="
81
81
  - !ruby/object:Gem::Version
82
82
  version: '0'
83
83
  - !ruby/object:Gem::Dependency
84
84
  name: footrest
85
85
  requirement: !ruby/object:Gem::Requirement
86
86
  requirements:
87
- - - '>='
87
+ - - ">="
88
88
  - !ruby/object:Gem::Version
89
89
  version: 0.2.2
90
90
  type: :runtime
91
91
  prerelease: false
92
92
  version_requirements: !ruby/object:Gem::Requirement
93
93
  requirements:
94
- - - '>='
94
+ - - ">="
95
95
  - !ruby/object:Gem::Version
96
96
  version: 0.2.2
97
97
  description: Ruby interface for interacting with the canvas API
@@ -103,7 +103,9 @@ extra_rdoc_files: []
103
103
  files:
104
104
  - Rakefile
105
105
  - bearcat.gemspec
106
+ - lib/bearcat.rb
106
107
  - lib/bearcat/api_array.rb
108
+ - lib/bearcat/client.rb
107
109
  - lib/bearcat/client/account_reports.rb
108
110
  - lib/bearcat/client/accounts.rb
109
111
  - lib/bearcat/client/assignment_groups.rb
@@ -128,9 +130,7 @@ files:
128
130
  - lib/bearcat/client/sections.rb
129
131
  - lib/bearcat/client/submissions.rb
130
132
  - lib/bearcat/client/users.rb
131
- - lib/bearcat/client.rb
132
133
  - lib/bearcat/version.rb
133
- - lib/bearcat.rb
134
134
  - spec/bearcat/client/accounts_spec.rb
135
135
  - spec/bearcat/client/assignment_groups_spec.rb
136
136
  - spec/bearcat/client/assignments_spec.rb
@@ -164,6 +164,7 @@ files:
164
164
  - spec/fixtures/accounts.json
165
165
  - spec/fixtures/add_custom_user_data.json
166
166
  - spec/fixtures/add_user.json
167
+ - spec/fixtures/assignment.json
167
168
  - spec/fixtures/assignment_groups.json
168
169
  - spec/fixtures/assignment_section_override.json
169
170
  - spec/fixtures/assignments.json
@@ -239,17 +240,17 @@ require_paths:
239
240
  - lib
240
241
  required_ruby_version: !ruby/object:Gem::Requirement
241
242
  requirements:
242
- - - '>='
243
+ - - ">="
243
244
  - !ruby/object:Gem::Version
244
245
  version: '0'
245
246
  required_rubygems_version: !ruby/object:Gem::Requirement
246
247
  requirements:
247
- - - '>='
248
+ - - ">="
248
249
  - !ruby/object:Gem::Version
249
250
  version: '0'
250
251
  requirements: []
251
252
  rubyforge_project:
252
- rubygems_version: 2.0.14
253
+ rubygems_version: 2.4.5
253
254
  signing_key:
254
255
  specification_version: 4
255
256
  summary: Canvas API
@@ -287,6 +288,7 @@ test_files:
287
288
  - spec/fixtures/accounts.json
288
289
  - spec/fixtures/add_custom_user_data.json
289
290
  - spec/fixtures/add_user.json
291
+ - spec/fixtures/assignment.json
290
292
  - spec/fixtures/assignment_groups.json
291
293
  - spec/fixtures/assignment_section_override.json
292
294
  - spec/fixtures/assignments.json
@@ -353,4 +355,3 @@ test_files:
353
355
  - spec/fixtures/user_page_views.json
354
356
  - spec/fixtures/user_profile.json
355
357
  - spec/helper.rb
356
- has_rdoc: