ungulate 0.0.11 → 0.0.12

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.
data/VERSION CHANGED
@@ -1 +1 @@
1
- 0.0.11
1
+ 0.0.12
@@ -64,6 +64,7 @@ module Ungulate
64
64
 
65
65
  def process
66
66
  return false if processed_versions.empty?
67
+
67
68
  processed_versions.each do |version, image|
68
69
  version_key = version_key version
69
70
  @logger.info "Storing #{version} @ #{version_key}"
@@ -80,7 +81,10 @@ module Ungulate
80
81
  )
81
82
  image.destroy!
82
83
  end
84
+
83
85
  send_notification
86
+
87
+ true
84
88
  end
85
89
 
86
90
  def send_notification
@@ -181,11 +181,10 @@ module Ungulate
181
181
  job
182
182
  end
183
183
 
184
- after { subject.process }
185
-
186
184
  it "should destroy the image objects" do
187
185
  @big.should_receive(:destroy!)
188
186
  @little.should_receive(:destroy!)
187
+ subject.process
189
188
  end
190
189
 
191
190
  it "should send each processed version to S3" do
@@ -204,10 +203,22 @@ module Ungulate
204
203
  {},
205
204
  'public-read',
206
205
  expected_headers)
206
+ subject.process
207
207
  end
208
208
 
209
209
  it "should notify" do
210
210
  subject.should_receive(:send_notification)
211
+ subject.process
212
+ end
213
+
214
+ context "send_notification returns false" do
215
+ before do
216
+ subject.stub(:send_notification).and_return(false)
217
+ end
218
+
219
+ it "should return true" do
220
+ subject.process.should be_true
221
+ end
211
222
  end
212
223
 
213
224
  context "empty array" do
@@ -216,6 +227,7 @@ module Ungulate
216
227
  end
217
228
 
218
229
  it "should not break" do
230
+ subject.process
219
231
  end
220
232
  end
221
233
  end
@@ -5,11 +5,11 @@
5
5
 
6
6
  Gem::Specification.new do |s|
7
7
  s.name = %q{ungulate}
8
- s.version = "0.0.11"
8
+ s.version = "0.0.12"
9
9
 
10
10
  s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
11
11
  s.authors = ["Andrew Bruce"]
12
- s.date = %q{2010-10-13}
12
+ s.date = %q{2010-11-03}
13
13
  s.default_executable = %q{ungulate_server.rb}
14
14
  s.description = %q{WIP}
15
15
  s.email = %q{andrew@camelpunch.com}
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: ungulate
3
3
  version: !ruby/object:Gem::Version
4
- hash: 9
4
+ hash: 7
5
5
  prerelease: false
6
6
  segments:
7
7
  - 0
8
8
  - 0
9
- - 11
10
- version: 0.0.11
9
+ - 12
10
+ version: 0.0.12
11
11
  platform: ruby
12
12
  authors:
13
13
  - Andrew Bruce
@@ -15,7 +15,7 @@ autorequire:
15
15
  bindir: bin
16
16
  cert_chain: []
17
17
 
18
- date: 2010-10-13 00:00:00 +01:00
18
+ date: 2010-11-03 00:00:00 +00:00
19
19
  default_executable: ungulate_server.rb
20
20
  dependencies:
21
21
  - !ruby/object:Gem::Dependency