

@defer.inlineCallbacks
def prepareRoutingsAndStartConnector(self, connector):
    self.AckServerResource.render_GET = mock.Mock(wraps=self.AckServerResource.render_GET)
    connector.port = connector.SMSCPort.getHost().port
    c2_destination = HttpConnector(id_generator(), ('http://127.0.0.1:%s/send' % self.AckServer.getHost().port))
    (yield self.moroute_add(DefaultRoute(c2_destination), 0))
    (yield self.SMPPClientManagerPBProxy.connect('127.0.0.1', self.CManagerPort))
    c1Config = SMPPClientConfig(id=connector.cid, port=connector.port)
    (yield self.SMPPClientManagerPBProxy.add(c1Config))
    (yield self.SMPPClientManagerPBProxy.start(connector.cid))
    while True:
        ssRet = (yield self.SMPPClientManagerPBProxy.session_state(connector.cid))
        if (ssRet == 'BOUND_TRX'):
            break
        else:
            time.sleep(0.2)

dataset/ETHPy150Open jookies/jasmin/jasmin/routing/test/test_routing_deliver_sm.py DeliverSmHttpThrowingTestCases.prepareRoutingsAndStartConnector/VarMisuse@40/53 `self`->`connector`