npo_assets 0.3.0 → 0.3.1
Sign up to get free protection for your applications and to get access to all the features.
- data/VERSION +1 -1
- data/lib/npo_assets/asset.rb +1 -1
- data/npo_assets.gemspec +1 -1
- data/spec/npo_assets/asset_spec.rb +4 -4
- metadata +2 -2
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
0.3.
|
1
|
+
0.3.1
|
data/lib/npo_assets/asset.rb
CHANGED
data/npo_assets.gemspec
CHANGED
@@ -230,8 +230,8 @@ describe NPO::Assets::Asset do
|
|
230
230
|
|
231
231
|
@object1 = mock("Asset")
|
232
232
|
@object2 = mock("Asset")
|
233
|
-
NPO::Assets::Asset.stub!(:find_or_create_by_url_and_remote_id).with("000/000/001.jpg",
|
234
|
-
NPO::Assets::Asset.stub!(:find_or_create_by_url_and_remote_id).with("000/000/002.jpg",
|
233
|
+
NPO::Assets::Asset.stub!(:find_or_create_by_url_and_remote_id).with("000/000/001.jpg", 1).and_return @object1
|
234
|
+
NPO::Assets::Asset.stub!(:find_or_create_by_url_and_remote_id).with("000/000/002.jpg", 2).and_return @object2
|
235
235
|
|
236
236
|
NPO::Assets::Asset.stub!(:get).and_return @response
|
237
237
|
end
|
@@ -246,8 +246,8 @@ describe NPO::Assets::Asset do
|
|
246
246
|
end
|
247
247
|
|
248
248
|
it "should generate new assets for each returned asset" do
|
249
|
-
NPO::Assets::Asset.should_receive(:find_or_create_by_url_and_remote_id).with("000/000/001.jpg",
|
250
|
-
NPO::Assets::Asset.should_receive(:find_or_create_by_url_and_remote_id).with("000/000/002.jpg",
|
249
|
+
NPO::Assets::Asset.should_receive(:find_or_create_by_url_and_remote_id).with("000/000/001.jpg", 1).once
|
250
|
+
NPO::Assets::Asset.should_receive(:find_or_create_by_url_and_remote_id).with("000/000/002.jpg", 2).once
|
251
251
|
do_list
|
252
252
|
end
|
253
253
|
|