summaryrefslogtreecommitdiff
path: root/test/lib/engines.py
diff options
context:
space:
mode:
Diffstat (limited to 'test/lib/engines.py')
-rw-r--r--test/lib/engines.py13
1 files changed, 13 insertions, 0 deletions
diff --git a/test/lib/engines.py b/test/lib/engines.py
index 6202c0a3d..7b830e643 100644
--- a/test/lib/engines.py
+++ b/test/lib/engines.py
@@ -51,6 +51,19 @@ class ConnectionKiller(object):
# self._safe(conn.rollback)
def _stop_test_ctx(self):
+ if config.options.low_connections:
+ self._stop_test_ctx_minimal()
+ else:
+ self._stop_test_ctx_aggressive()
+
+ def _stop_test_ctx_minimal(self):
+ from test.lib import testing
+ self.close_all()
+ for rec in self.testing_engines.keys():
+ if rec is not testing.db:
+ rec.dispose()
+
+ def _stop_test_ctx_aggressive(self):
self.close_all()
for conn in self.conns:
self._safe(conn.close)