- Added Database#filter{|doc| .. } for doing temp queries with ruby
[couchobject.git] / spec / integration / integration_helper.rb
blob4e78e5aaf1c742e0fb921547406b620a0f50d9bc
1 require File.dirname(__FILE__) + '/../spec_helper.rb'
3 module IntegrationSpecHelper
4   def create_test_db(name="couchobject_test")
5     CouchObject::Database.create!("http://localhost:8888", name)
6   end
7   
8   def open_test_db(name="couchobject_test")
9     CouchObject::Database.open("http://localhost:8888/#{name}")    
10   end
11   
12   def delete_test_db(name="couchobject_test")
13     CouchObject::Database.delete!("http://localhost:8888", "couchobject_test")
14   end
15   
16   def create_and_open_test_db(name="couchobject_test")
17     create_test_db(name)
18     open_test_db(name)
19   end
20 end