From f8e8686537e35c27b3c7fa26db89845138059827 Mon Sep 17 00:00:00 2001 From: Chris Anderson Date: Fri, 27 Feb 2009 10:58:48 -0800 Subject: [PATCH 1/2] fixed db spec --- spec/couchrest/core/database_spec.rb | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/spec/couchrest/core/database_spec.rb b/spec/couchrest/core/database_spec.rb index 18711ef..dd8c3df 100644 --- a/spec/couchrest/core/database_spec.rb +++ b/spec/couchrest/core/database_spec.rb @@ -312,8 +312,9 @@ describe CouchRest::Database do } } @db.save_doc(doc) + doc['_rev'].should_not be_nil doc['field'] << 'another value' - @db.save_doc(doc).should be_true + @db.save_doc(doc)["ok"].should be_true end it 'should be there' do From 70d594ff5c11a6444e0499eb12d682bfb1294d3e Mon Sep 17 00:00:00 2001 From: Chris Anderson Date: Fri, 27 Feb 2009 12:27:52 -0800 Subject: [PATCH 2/2] dcnstrct says Timeout::Error is the constant we probably mean --- lib/couchrest/monkeypatches.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/couchrest/monkeypatches.rb b/lib/couchrest/monkeypatches.rb index 99e1cff..56942be 100644 --- a/lib/couchrest/monkeypatches.rb +++ b/lib/couchrest/monkeypatches.rb @@ -37,7 +37,7 @@ if RUBY_VERSION.to_f < 1.9 if IO.select([@io], nil, nil, @read_timeout) @rbuf << @io.read_nonblock(65536) else - raise Timeout::TimeoutError + raise Timeout::Error end end end