PYTHON-2779 Fix topologies field in snapshot reads test (#657)
This commit is contained in:
parent
a94504bde9
commit
354c96a414
@ -673,6 +673,10 @@ class ClientContext(object):
|
||||
func=func)
|
||||
|
||||
def is_topology_type(self, topologies):
|
||||
unknown = set(topologies) - {'single', 'replicaset', 'sharded',
|
||||
'sharded-replicaset', 'load-balanced'}
|
||||
if unknown:
|
||||
raise AssertionError('Unknown topologies: %r' % (unknown,))
|
||||
if self.load_balancer:
|
||||
if 'load-balanced' in topologies:
|
||||
return True
|
||||
|
||||
@ -4,9 +4,12 @@
|
||||
"runOnRequirements": [
|
||||
{
|
||||
"minServerVersion": "3.6",
|
||||
"maxServerVersion": "4.4.99",
|
||||
"maxServerVersion": "4.4.99"
|
||||
},
|
||||
{
|
||||
"minServerVersion": "3.6",
|
||||
"topologies": [
|
||||
"replicaset, sharded-replicaset"
|
||||
"single"
|
||||
]
|
||||
}
|
||||
],
|
||||
@ -17,6 +20,11 @@
|
||||
"observeEvents": [
|
||||
"commandStartedEvent",
|
||||
"commandFailedEvent"
|
||||
],
|
||||
"ignoreCommandMonitoringEvents": [
|
||||
"findAndModify",
|
||||
"insert",
|
||||
"update"
|
||||
]
|
||||
}
|
||||
},
|
||||
@ -87,9 +95,7 @@
|
||||
"$$exists": false
|
||||
}
|
||||
}
|
||||
},
|
||||
"commandName": "find",
|
||||
"databaseName": "database0"
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
|
||||
Loading…
Reference in New Issue
Block a user