Commit be7612be authored by Tim Peters's avatar Tim Peters

checkQuickVerificationWith2Clients(): close perstorage at the end.

Otherwise the temp zec file can't be deleted on Windows.
parent 97807b5d
...@@ -463,7 +463,7 @@ class ConnectionTests(CommonSetupTearDown): ...@@ -463,7 +463,7 @@ class ConnectionTests(CommonSetupTearDown):
self._storage = self.openClientStorage() self._storage = self.openClientStorage()
self._dostore() self._dostore()
# Test case for multiple storages participating in a single # Test case for multiple storages participating in a single
# transaction. This is not really a connection test, but it needs # transaction. This is not really a connection test, but it needs
# about the same infrastructure (several storage servers). # about the same infrastructure (several storage servers).
...@@ -507,7 +507,7 @@ class ConnectionTests(CommonSetupTearDown): ...@@ -507,7 +507,7 @@ class ConnectionTests(CommonSetupTearDown):
r1["a"] = MinPO("a") r1["a"] = MinPO("a")
get_transaction().commit() get_transaction().commit()
db2 = DB(self.openClientStorage()) db2 = DB(self.openClientStorage())
r2 = db2.open().root() r2 = db2.open().root()
...@@ -533,7 +533,7 @@ class ConnectionTests(CommonSetupTearDown): ...@@ -533,7 +533,7 @@ class ConnectionTests(CommonSetupTearDown):
db2.close() db2.close()
db1.close() db1.close()
class ReconnectionTests(CommonSetupTearDown): class ReconnectionTests(CommonSetupTearDown):
keep = 1 keep = 1
invq = 2 invq = 2
...@@ -687,11 +687,11 @@ class ReconnectionTests(CommonSetupTearDown): ...@@ -687,11 +687,11 @@ class ReconnectionTests(CommonSetupTearDown):
# There were no transactions committed, so no verification # There were no transactions committed, so no verification
# should be needed. # should be needed.
self.assertEqual(self._storage.verify_result, "no verification") self.assertEqual(self._storage.verify_result, "no verification")
def checkNoVerificationOnServerRestartWith2Clients(self): def checkNoVerificationOnServerRestartWith2Clients(self):
perstorage = self.openClientStorage(cache="test") perstorage = self.openClientStorage(cache="test")
self.assertEqual(perstorage.verify_result, "full verification") self.assertEqual(perstorage.verify_result, "full verification")
self._storage = self.openClientStorage() self._storage = self.openClientStorage()
oid = self._storage.new_oid() oid = self._storage.new_oid()
# When we create a new storage, it should always do a full # When we create a new storage, it should always do a full
...@@ -722,7 +722,7 @@ class ReconnectionTests(CommonSetupTearDown): ...@@ -722,7 +722,7 @@ class ReconnectionTests(CommonSetupTearDown):
def checkQuickVerificationWith2Clients(self): def checkQuickVerificationWith2Clients(self):
perstorage = self.openClientStorage(cache="test") perstorage = self.openClientStorage(cache="test")
self.assertEqual(perstorage.verify_result, "full verification") self.assertEqual(perstorage.verify_result, "full verification")
self._storage = self.openClientStorage() self._storage = self.openClientStorage()
oid = self._storage.new_oid() oid = self._storage.new_oid()
# When we create a new storage, it should always do a full # When we create a new storage, it should always do a full
...@@ -735,7 +735,7 @@ class ReconnectionTests(CommonSetupTearDown): ...@@ -735,7 +735,7 @@ class ReconnectionTests(CommonSetupTearDown):
perstorage.load(oid, '') perstorage.load(oid, '')
perstorage.close() perstorage.close()
revid = self._dostore(oid, revid) revid = self._dostore(oid, revid)
perstorage = self.openClientStorage(cache="test") perstorage = self.openClientStorage(cache="test")
...@@ -743,13 +743,14 @@ class ReconnectionTests(CommonSetupTearDown): ...@@ -743,13 +743,14 @@ class ReconnectionTests(CommonSetupTearDown):
self.assertEqual(perstorage.load(oid, ''), self.assertEqual(perstorage.load(oid, ''),
self._storage.load(oid, '')) self._storage.load(oid, ''))
perstorage.close()
def checkVerificationWith2ClientsInvqOverflow(self): def checkVerificationWith2ClientsInvqOverflow(self):
perstorage = self.openClientStorage(cache="test") perstorage = self.openClientStorage(cache="test")
self.assertEqual(perstorage.verify_result, "full verification") self.assertEqual(perstorage.verify_result, "full verification")
self._storage = self.openClientStorage() self._storage = self.openClientStorage()
oid = self._storage.new_oid() oid = self._storage.new_oid()
# When we create a new storage, it should always do a full # When we create a new storage, it should always do a full
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment