Commit 16d84f10 authored by Kirill Smelkov's avatar Kirill Smelkov

.

parent fb8eaf3b
...@@ -126,6 +126,7 @@ class NeoTestRunner(unittest.TextTestResult): ...@@ -126,6 +126,7 @@ class NeoTestRunner(unittest.TextTestResult):
print "Import of %s failed : %s" % (test_module, err) print "Import of %s failed : %s" % (test_module, err)
traceback.print_exc() traceback.print_exc()
continue continue
if 1 or test_module.__name__ == 'neo.tests.functional.testStorage':
suite.addTests(loader.loadTestsFromModule(test_module)) suite.addTests(loader.loadTestsFromModule(test_module))
suite.run(self) suite.run(self)
......
...@@ -226,7 +226,8 @@ class ClusterPdb(object): ...@@ -226,7 +226,8 @@ class ClusterPdb(object):
def wait(self, test, timeout): def wait(self, test, timeout):
end_time = time() + timeout end_time = time() + timeout
period = 0.1 #period = 0.1
period = 0.05
while not test(): while not test():
cluster_dict.acquire() cluster_dict.acquire()
try: try:
...@@ -237,11 +238,12 @@ class ClusterPdb(object): ...@@ -237,11 +238,12 @@ class ClusterPdb(object):
next_sleep = max(last_pdb + timeout, end_time) - time() next_sleep = max(last_pdb + timeout, end_time) - time()
if next_sleep > period: if next_sleep > period:
next_sleep = period next_sleep = period
period *= 1.5 #period *= 1.5
elif next_sleep < 0: elif next_sleep < 0:
return False return False
finally: finally:
cluster_dict.release() cluster_dict.release()
#print 'next_sleep:', next_sleep
sleep(next_sleep) sleep(next_sleep)
return True return True
......
...@@ -34,7 +34,7 @@ class MasterClientHandlerTests(NeoUnitTestBase): ...@@ -34,7 +34,7 @@ class MasterClientHandlerTests(NeoUnitTestBase):
self.app.em = Mock() self.app.em = Mock()
self.app.loid = '\0' * 8 self.app.loid = '\0' * 8
self.app.tm.setLastTID('\0' * 8) self.app.tm.setLastTID('\0' * 8)
self.service = ClientServiceHandler(self.app) self.service = ClientServiceHandler(self.app) # TODO tests for RO handler
# define some variable to simulate client and storage node # define some variable to simulate client and storage node
self.client_port = 11022 self.client_port = 11022
self.storage_port = 10021 self.storage_port = 10021
......
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