rivendell-api 0.0.1 → 0.0.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -94,4 +94,26 @@ describe Rivendell::API::Xport do
94
94
 
95
95
  end
96
96
 
97
+ describe "list_carts" do
98
+
99
+ before(:each) do
100
+ FakeWeb.register_uri(:post, "http://localhost/rd-bin/rdxport.cgi", :body => fixture_content("rdxport_list_carts.xml"))
101
+ end
102
+
103
+ it "should use COMMAND 6" do
104
+ subject.list_carts
105
+ FakeWeb.last_request["COMMAND"] == "6"
106
+ end
107
+
108
+ it "should return Casts" do
109
+ subject.list_carts.map(&:title).should include("Rivendell 1", "Rivendell 2", "Rivendell 3")
110
+ end
111
+
112
+ it "should use group as group_name" do
113
+ subject.list_carts :group => "TEST"
114
+ FakeWeb.last_request["GROUP_NAME"] == "TEST"
115
+ end
116
+
117
+ end
118
+
97
119
  end
data/spec/spec_helper.rb CHANGED
@@ -8,6 +8,8 @@ require 'rivendell/api'
8
8
 
9
9
  Dir[File.expand_path(File.join(File.dirname(__FILE__),'support','**','*.rb'))].each {|f| require f}
10
10
 
11
+ FileUtils.mkdir_p "log"
12
+
11
13
  require "logger"
12
14
  Rivendell::API.logger = Logger.new("log/test.log")
13
15
 
data/tasks/rdoc.rake CHANGED
@@ -1,4 +1,11 @@
1
- require 'rdoc/task'
1
+ begin
2
+ require 'rdoc/task'
3
+ rescue LoadError
4
+ require 'rdoc/rdoc'
5
+ require 'rake/rdoctask'
6
+ RDoc::Task = Rake::RDocTask
7
+ end
8
+
2
9
  Rake::RDocTask.new do |rdoc|
3
10
  version = File.exist?('VERSION') ? File.read('VERSION') : ""
4
11
 
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: rivendell-api
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.1
4
+ version: 0.0.2
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2012-09-14 00:00:00.000000000 Z
12
+ date: 2012-10-03 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: httmultiparty
@@ -28,7 +28,7 @@ dependencies:
28
28
  - !ruby/object:Gem::Version
29
29
  version: '0'
30
30
  - !ruby/object:Gem::Dependency
31
- name: active_support
31
+ name: activesupport
32
32
  requirement: !ruby/object:Gem::Requirement
33
33
  none: false
34
34
  requirements:
@@ -181,6 +181,7 @@ files:
181
181
  - spec/fixtures/rdxport_add_cart.xml
182
182
  - spec/fixtures/rdxport_add_cut.xml
183
183
  - spec/fixtures/rdxport_import.xml
184
+ - spec/fixtures/rdxport_list_carts.xml
184
185
  - spec/fixtures/rdxport_list_groups.xml
185
186
  - spec/rivendell/api/xport_spec.rb
186
187
  - spec/spec_helper.rb
@@ -201,7 +202,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
201
202
  version: '0'
202
203
  segments:
203
204
  - 0
204
- hash: -1014058537179393572
205
+ hash: -4338672299131379254
205
206
  required_rubygems_version: !ruby/object:Gem::Requirement
206
207
  none: false
207
208
  requirements:
@@ -210,7 +211,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
210
211
  version: '0'
211
212
  segments:
212
213
  - 0
213
- hash: -1014058537179393572
214
+ hash: -4338672299131379254
214
215
  requirements: []
215
216
  rubyforge_project:
216
217
  rubygems_version: 1.8.23
@@ -222,6 +223,7 @@ test_files:
222
223
  - spec/fixtures/rdxport_add_cart.xml
223
224
  - spec/fixtures/rdxport_add_cut.xml
224
225
  - spec/fixtures/rdxport_import.xml
226
+ - spec/fixtures/rdxport_list_carts.xml
225
227
  - spec/fixtures/rdxport_list_groups.xml
226
228
  - spec/rivendell/api/xport_spec.rb
227
229
  - spec/spec_helper.rb