MCPcopy Create free account
hub / github.com/mongodb/mongo-python-driver / supports_transactions

Method supports_transactions

test/__init__.py:764–771  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

762 )
763
764 def supports_transactions(self):
765 if self.version.at_least(4, 1, 8):
766 return self.is_mongos or self.is_rs
767
768 if self.version.at_least(4, 0):
769 return self.is_rs
770
771 return False
772
773 def require_transactions(self, func):
774 """Run a test only if the deployment might support transactions.

Callers 3

setUpMethod · 0.45
setUpMethod · 0.45
setUpMethod · 0.45

Calls 1

at_leastMethod · 0.80

Tested by 2

setUpMethod · 0.36
setUpMethod · 0.36