fixed the database attachment specs

This commit is contained in:
Matt Aimonetti 2009-07-29 19:01:38 -07:00
parent 9141669df1
commit beb801d1bd

View file

@ -368,8 +368,9 @@ describe CouchRest::Database do
end end
it "should delete the attachment" do it "should delete the attachment" do
lambda { @db.fetch_attachment(@doc,'test.html') }.should_not raise_error lambda { @db.fetch_attachment(@doc,'test.html') }.should_not raise_error
@db.delete_attachment(@doc, "test.html") @db.delete_attachment(@doc, "test.html")
@db.fetch_attachment(@doc,'test.html').should be_nil @doc = @db.get('mydocwithattachment') # avoid getting a 409
lambda{ @db.fetch_attachment(@doc,'test.html')}.should raise_error
end end
end end