Commit 912e0a4d authored by Grégory Wisniewski's avatar Grégory Wisniewski

Fix bad indentation in tests modules.


git-svn-id: https://svn.erp5.org/repos/neo/trunk@1345 71dcc9de-d417-0410-9af5-da40c76e7ee4
parent e3926ad4
......@@ -327,6 +327,7 @@ class DoNothingConnector(Mock):
class TestElectionConnector(DoNothingConnector):
def receive(self):
""" simulate behavior of election """
if self.packet_cpt == 0:
......@@ -334,14 +335,8 @@ class TestElectionConnector(DoNothingConnector):
logging.info("in patched analyse / IDENTIFICATION")
p = protocol.Packet()
self.uuid = getNewUUID()
p.acceptNodeIdentification(1,
NodeType.MASTER,
self.uuid,
self.getAddress()[0],
self.getAddress()[1],
1009,
2
)
p.acceptNodeIdentification(1, NodeType.MASTER, self.uuid,
self.getAddress()[0], self.getAddress()[1], 1009, 2)
self.packet_cpt += 1
return p.encode()
elif self.packet_cpt == 1:
......
......@@ -296,8 +296,7 @@ class NEOCluster(object):
for master in self.getMasterProcessList():
master_uuid = master.getUUID()
is_primary = master_uuid == primary_uuid
if primary and is_primary or \
not (primary or is_primary):
if primary and is_primary or not (primary or is_primary):
killed_uuid_list.append(master_uuid)
master.kill()
master.wait()
......
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