diff --git a/lib/mongo/db.rb b/lib/mongo/db.rb index e1f48a8..67346a0 100644 --- a/lib/mongo/db.rb +++ b/lib/mongo/db.rb @@ -160,12 +160,12 @@ module XGen @socket.print(message.buf.to_s) end - protected - def full_coll_name(collection) "#{@name}.#{collection}" end + protected + def db_command(selector) # TODO synchronize q = Query.new(selector) diff --git a/tests/test_db_api.rb b/tests/test_db_api.rb index f6270c4..00bb845 100644 --- a/tests/test_db_api.rb +++ b/tests/test_db_api.rb @@ -76,4 +76,8 @@ class DBAPITest < Test::Unit::TestCase # Mongo bug: returns string with wrong length, so last byte of value is chopped off. # assert_equal @coll.name, row['options']['create'] end + + def test_full_coll_name + assert_equal @coll_full_name, @db.full_coll_name(@coll.name) + end end