canvas_cc 0.0.4 → 0.0.5

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: b302176d6eaee2ce216a6a88bc24e273cafd6852
4
- data.tar.gz: fdae3d4631f469a76067a8d22e8dc21eae129e42
3
+ metadata.gz: fc50be4e2acf75a525a68008378e88c37a9d00ee
4
+ data.tar.gz: e2e5c8e089bdcd17942d43e14ccdf1ea00c08fa7
5
5
  SHA512:
6
- metadata.gz: e69f9bfc68f2fdbd9fccbf7d2900a3d8651c27118f031877bad9b49bf834378ee9dc94ff097ed4b2bd4aee543af219a4eb88d8b771659afa7a057b63dea37ae9
7
- data.tar.gz: 07691d2ea03ebe876d0bae672534dd24ec68b1c38640877e91186488a9146f7184ea573cbb0808970b3b79b3484cd9d8f59cf049918a3fcf38a1e0eada04c6e7
6
+ metadata.gz: 2bd4bc90a7c96675548bf3fad16913c3e56be5fe11550cca20d4ca1892d0d2c0bd0462fca949ff68cfffee44815f9e28814bf97d47aaefbf916c2e5d74ced60d
7
+ data.tar.gz: 22ba9d035d3675e98f9a9bf1442cfbbf4b87afe583aa3bddb113e1a2fa0393d543c948ff2953ead17241892846d3cea3e2083a371d4062ef29a504be8be43a82
data/canvas_cc.gemspec CHANGED
@@ -32,6 +32,6 @@ Gem::Specification.new do |spec|
32
32
  spec.add_development_dependency "guard-bundler"
33
33
  spec.add_development_dependency "guard-minitest"
34
34
  spec.add_development_dependency "guard-rspec"
35
- spec.add_development_dependency "debugger"
35
+ spec.add_development_dependency "byebug"
36
36
  spec.add_development_dependency "bundler", "~> 1.5"
37
37
  end
@@ -40,7 +40,7 @@ module CanvasCc::CanvasCC
40
40
  ) { |xml|
41
41
  xml.topic_id discussion_resource.identifier
42
42
  xml.title discussion.title
43
- xml.position
43
+ xml.position discussion.position
44
44
  xml.type 'topic'
45
45
  xml.discussion_type discussion.discussion_type
46
46
  xml.require_initial_post discussion.require_initial_post
@@ -1,6 +1,7 @@
1
1
  module CanvasCc::CanvasCC::Models
2
2
  class Discussion
3
- attr_accessor :identifier, :title, :text, :discussion_type, :workflow_state, :require_initial_post, :assignment
3
+ attr_accessor :identifier, :title, :text, :discussion_type, :workflow_state, :require_initial_post,
4
+ :assignment, :position
4
5
  DISCUSSION_ID_POSTFIX = '_DISCUSSION'
5
6
  DISCUSSION_META_POSTFIX = '_meta'
6
7
  IMSDT_TYPE = 'imsdt_xmlv1p1'
@@ -1,3 +1,3 @@
1
1
  module CanvasCc
2
- VERSION = "0.0.4"
2
+ VERSION = "0.0.5"
3
3
  end
@@ -26,13 +26,14 @@ describe CanvasCc::CanvasCC::DiscussionWriter do
26
26
  discussion.title = 'Discussion Title'
27
27
  discussion.text = '<p>discussion_text</p>'
28
28
  discussion.discussion_type = 'threaded'
29
+ discussion.position = '1'
29
30
  writer.write
30
31
  xml = Nokogiri::XML(File.read(File.join(work_dir, discussion.meta_resource.href)))
31
32
  expect(xml.at_xpath('xmlns:topicMeta/@identifier').value).to eq('discussion_id_meta')
32
33
  expect(xml.%('topicMeta/topic_id').text).to eq 'discussion_id'
33
34
  expect(xml.%('topicMeta/title').text).to eq 'Discussion Title'
34
35
  expect(xml.%('topicMeta/type').text).to eq 'topic'
35
- expect(xml.%('topicMeta/position').text).to eq ''
36
+ expect(xml.%('topicMeta/position').text).to eq '1'
36
37
  expect(xml.%('topicMeta/discussion_type').text).to eq 'threaded'
37
38
  end
38
39
 
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: canvas_cc
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.4
4
+ version: 0.0.5
5
5
  platform: ruby
6
6
  authors:
7
7
  - Instructure
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2014-10-08 00:00:00.000000000 Z
11
+ date: 2014-10-22 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rubyzip
@@ -193,7 +193,7 @@ dependencies:
193
193
  - !ruby/object:Gem::Version
194
194
  version: '0'
195
195
  - !ruby/object:Gem::Dependency
196
- name: debugger
196
+ name: byebug
197
197
  requirement: !ruby/object:Gem::Requirement
198
198
  requirements:
199
199
  - - ">="