spec/lib/locator_spec.rb in stowaway-0.2.0 vs spec/lib/locator_spec.rb in stowaway-0.2.2
- old
+ new
@@ -16,12 +16,12 @@
@f1 = Stowaway::FileObj.new('spec/data/testfile1.txt')
locator.find_all('spec/data')[1].instance_of?(Stowaway::FileObj).should be_true
end
it "should return all matched files" do
- @f1 = Stowaway::FileObj.new('spec/data/testfile1.txt')
- @f2 = Stowaway::FileObj.new('spec/data/testfile2.txt')
+ @f1 = Stowaway::FileObj.new('spec/data/testfile1.txt', "spec/data")
+ @f2 = Stowaway::FileObj.new('spec/data/testfile2.txt', "spec/data")
locator.find_all('spec/data/').should == [@f1, @f2]
end
it "should return true when file has the correct extension" do
locator.type?('poop.txt').should be_true
@@ -29,6 +29,7 @@
it "should return false when file doesn't have the correct extension" do
locator.type?('poop.stink').should be_false
end
-end
\ No newline at end of file
+end
+