Commit 780b3abc authored by Grégory Wisniewski's avatar Grégory Wisniewski

Update protocol.py tests according to commit #416


git-svn-id: https://svn.erp5.org/repos/neo/branches/prototype3@422 71dcc9de-d417-0410-9af5-da40c76e7ee4
parent efa09d24
......@@ -142,22 +142,24 @@ class testProtocol(unittest.TestCase):
def test_12_acceptNodeIdentification(self):
p = Packet()
uuid = self.getNewUUID()
uuid1, uuid2 = self.getNewUUID(), self.getNewUUID()
p.acceptNodeIdentification(1,
CLIENT_NODE_TYPE,
uuid,
uuid1,
"127.0.0.1",
9080,
10,
20
20,
uuid2
)
node, p_uuid, ip, port, nb_partitions, nb_replicas = p.decode()
node, p_uuid, ip, port, nb_partitions, nb_replicas, your_uuid = p.decode()
self.assertEqual(node, CLIENT_NODE_TYPE)
self.assertEqual(p_uuid, uuid)
self.assertEqual(p_uuid, uuid1)
self.assertEqual(ip, "127.0.0.1")
self.assertEqual(port, 9080)
self.assertEqual(nb_partitions, 10)
self.assertEqual(nb_replicas, 20)
self.assertEqual(your_uuid, uuid2)
def test_13_askPrimaryMaster(self):
p = Packet()
......
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