From 330ea82ce49b6c34f8efd7ecc92cac47e589bd58 Mon Sep 17 00:00:00 2001 From: Sam Saffron Date: Tue, 27 May 2014 13:52:39 +1000 Subject: [PATCH] FIX broken spec --- spec/components/cooked_post_processor_spec.rb | 16 +++++----------- 1 file changed, 5 insertions(+), 11 deletions(-) diff --git a/spec/components/cooked_post_processor_spec.rb b/spec/components/cooked_post_processor_spec.rb index d11ba9090..cd96514ad 100644 --- a/spec/components/cooked_post_processor_spec.rb +++ b/spec/components/cooked_post_processor_spec.rb @@ -47,15 +47,11 @@ describe CookedPostProcessor do before { cpp.post_process_images } - it "adds the width from the image sizes provided when no dimension is provided" do + it "works" do + # adds the width from the image sizes provided when no dimension is provided cpp.html.should =~ /src="http:\/\/foo.bar\/image.png" width="111" height="222"/ - end - - it "adds the width from the image sizes provided" do + # adds the width from the image sizes provided cpp.html.should =~ /src="http:\/\/domain.com\/picture.jpg" width="50" height="42"/ - end - - it "should be dirty" do cpp.should be_dirty end @@ -87,11 +83,9 @@ describe CookedPostProcessor do Upload.expects(:get_from_url).returns(upload) FastImage.stubs(:size).returns([1000, 2000]) - # optimized_image - FileUtils.stubs(:mkdir_p) - File.stubs(:open) + # hmmm this should be done in a cleaner way - OptimizedImage.any_instance.expects(:resize).returns(true) + OptimizedImage.expects(:resize).returns(true) end it "generates overlay information" do