spec/lib/sweeper_spec.rb in stowaway-0.1.2 vs spec/lib/sweeper_spec.rb in stowaway-0.1.5
- old
+ new
@@ -24,17 +24,29 @@
@files << Stowaway::FileObj.new("/fake/path/photo.jpg")
sweeper.sweep("spec/data")
@files.should be_empty
end
- it "should match images referenced in an href attribute when using haml" do
- @files << Stowaway::FileObj.new("/images/haml.jpg")
+ it "should match images referenced in a src attribute when files are stored in public folder" do
+ @files << Stowaway::FileObj.new("/public/fake/path1/button.jpg")
sweeper.sweep("spec/data")
@files.should be_empty
end
- it "should match images referenced in a src attribute when using haml" do
+ it "should match images referenced in an haml href attribute" do
+ @files << Stowaway::FileObj.new("/images/haml.jpg")
+ sweeper.sweep("spec/data")
+ @files.should be_empty
+ end
+
+ it "should match images referenced in a haml src attribute" do
@files << Stowaway::FileObj.new("/images/file.jpg")
+ sweeper.sweep("spec/data")
+ @files.should be_empty
+ end
+
+ it "should match images referenced in a haml src attribute when files are stored in public folder" do
+ @files << Stowaway::FileObj.new("/public/images/file.jpg")
sweeper.sweep("spec/data")
@files.should be_empty
end
it "should match scripts referenced in a src attribute" do