flixit 0.0.13 → 0.0.14

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.
Files changed (4) hide show
  1. data/VERSION +1 -1
  2. data/lib/flixit/job.rb +6 -2
  3. data/spec/job_spec.rb +13 -0
  4. metadata +3 -3
data/VERSION CHANGED
@@ -1 +1 @@
1
- 0.0.13
1
+ 0.0.14
data/lib/flixit/job.rb CHANGED
@@ -1,6 +1,6 @@
1
1
  class Flixit::Job < Flixit::Record
2
2
 
3
- attr_accessor :id, :initialized_at, :api_key, :recipe_id, :recipe_name, :response, :notification_url
3
+ attr_accessor :id, :initialized_at, :api_key, :recipe_id, :recipe_name, :response, :notification_url, :pass_through
4
4
 
5
5
  record_column :file_locations, 'FileLocations'
6
6
 
@@ -84,7 +84,11 @@ class Flixit::Job < Flixit::Record
84
84
  if notification_url
85
85
  xml.tag!('notification-url', notification_url)
86
86
  end
87
-
87
+
88
+ if pass_through
89
+ xml.tag!('pass-through', pass_through)
90
+ end
91
+
88
92
  if file_locations
89
93
  xml.tag!("file-locations") do
90
94
  if file_locations.input
data/spec/job_spec.rb CHANGED
@@ -22,4 +22,17 @@ context "Create a Job" do
22
22
  @job.save
23
23
  end
24
24
 
25
+ it "has a passthrough option" do
26
+ job = Flixit::Job.new(:recipe_id => 1,
27
+ :api_key => 'this_is_an_api_key',
28
+ :pass_through => YAML.dump({:key => 'value'}),
29
+ :file_locations => { :input => {:url => 'http://flixcloud.com/somefile.mp4'},
30
+ :output => {:url => 's3://flixcloud/somefile.flv'},
31
+ :thumbnails => {:url => "s3://flixcloud/somefile/",:prefix => 'thumbnail'}})
32
+ job.save
33
+
34
+ request = Crack::XML.parse Fredo.books.last[:body]
35
+ YAML.load(request['api_request']['pass_through']).should eql({:key => 'value'})
36
+ end
37
+
25
38
  end
metadata CHANGED
@@ -5,8 +5,8 @@ version: !ruby/object:Gem::Version
5
5
  segments:
6
6
  - 0
7
7
  - 0
8
- - 13
9
- version: 0.0.13
8
+ - 14
9
+ version: 0.0.14
10
10
  platform: ruby
11
11
  authors:
12
12
  - Leandro Pedroni
@@ -14,7 +14,7 @@ autorequire:
14
14
  bindir: bin
15
15
  cert_chain: []
16
16
 
17
- date: 2010-04-28 00:00:00 +01:00
17
+ date: 2010-05-03 00:00:00 +01:00
18
18
  default_executable:
19
19
  dependencies:
20
20
  - !ruby/object:Gem::Dependency