public
Fork of halfbyte/couchobject
Description: Library to access couchdb in ruby
Homepage: http://couchobject.rubyforge.org
Clone URL: git://github.com/jnunemaker/couchobject.git
Search Repo:
minor tweaks to persistable specs
jnunemaker (author)
Wed May 07 19:56:35 -0700 2008
commit  af07495f4ecf2fe40915985552de03977cfd866d
tree    3a7a2da466aba4836e1ad66ed59e6de90dd647e6
parent  890950623ff813b2ea42879d51da5950b29eb366
...
46
47
48
49
50
51
52
53
 
 
54
55
56
...
67
68
69
70
 
71
72
73
...
46
47
48
 
 
 
 
 
49
50
51
52
53
...
64
65
66
 
67
68
69
70
0
@@ -46,11 +46,8 @@
0
     proc{ klass.new.to_json }.should raise_error(CouchObject::Persistable::NoToCouchMethodError)
0
   end
0
   
0
- it "should raise if no to_couch on class" do
0
- klass = Class.new{
0
- include CouchObject::Persistable
0
- def to_couch() end
0
- }
0
+ it "should raise if no from_couch on class" do
0
+ klass = Class.new{ include CouchObject::Persistable }
0
     proc{ klass.get_by_id("foo", "bar") }.should raise_error(CouchObject::Persistable::NoFromCouchMethodError)
0
   end
0
   
0
@@ -67,7 +64,7 @@
0
     @bike.id.should == "123BAC"
0
   end
0
   
0
- it "should know if itself is a new object" do
0
+ it "should know if it is a new object" do
0
     CouchObject::Database.should_receive(:open).and_return(@db)
0
     @db.should_receive(:post).with("", @bike.to_json).and_return(@document_response)
0
     @bike.new?.should == true

Comments

    No one has commented yet.