Exemple #1
0
 def send_connect(self):
     connect = Connect()
     self.sock.sendall(connect.pack())
     self.sock.recv(1024)
Exemple #2
0
 def send_connect(self):
     connect = Connect()
     self.sock.sendall(connect.pack())
     self.sock.recv(1024)
Exemple #3
0
 def test_connect(self):
     command = Connect()
     response = self._send_command(command.pack())
     self.assertEqual(Connected().pack(), response)
Exemple #4
0
 def test_pack(self):
     packet = Connect()
     self.assertEqual(b'\x00\x00\x00\x010', packet.pack())
Exemple #5
0
 def test_init(self):
     packet = Connect()
     self.assertEqual(CONNECT, packet.command)
Exemple #6
0
 def test_connect(self):
     command = Connect()
     response = self._send_command(command.pack())
     self.assertEqual(Connected().pack(), response)