minor: replica set test fixes
This commit is contained in:
parent
8b2de82464
commit
e8a5375cbf
|
@ -158,7 +158,7 @@ module Mongo
|
|||
if !config['hosts']
|
||||
message = "Will not connect to #{host_string} because it's not a member " +
|
||||
"of a replica set."
|
||||
raise ReplicaSetConnectionError, message
|
||||
raise ConnectionFailure, message
|
||||
end
|
||||
end
|
||||
|
||||
|
@ -171,7 +171,7 @@ module Mongo
|
|||
elsif self.connection.replica_set_name != config['setName']
|
||||
message = "Attempting to connect to replica set '#{config['setName']}' on member #{host_string} " +
|
||||
"but expected '#{self.connection.replica_set_name}'"
|
||||
raise ReplicaSetConnectionError, message
|
||||
raise ConnectionFailure, message
|
||||
end
|
||||
end
|
||||
end
|
||||
|
|
|
@ -354,7 +354,7 @@ module Mongo
|
|||
if @primary_pool
|
||||
begin
|
||||
socket = @primary_pool.checkout
|
||||
@sockets_to_pools[socket] = @primary
|
||||
@sockets_to_pools[socket] = @primary_pool
|
||||
return socket
|
||||
rescue NoMethodError
|
||||
end
|
||||
|
|
|
@ -94,6 +94,7 @@ module Mongo
|
|||
@read_pool = manager.read_pool
|
||||
@arbiters = manager.arbiters
|
||||
@hosts = manager.hosts
|
||||
@tags_to_pools = {}
|
||||
end
|
||||
|
||||
def initialize_data
|
||||
|
|
Loading…
Reference in New Issue