def setUp(self): self.protocol = Device('COM3') self.transport = proto_helpers.StringTransport() self.protocol.makeConnection(self.transport)