class TestInPortPushConnector(unittest.TestCase): def setUp(self): OpenRTM_aist.Manager.instance() self._con = InPortPushConnector(OpenRTM_aist.ConnectorInfo("name","id",[],OpenRTM_aist.Properties()),InPortProviderMock(),OpenRTM_aist.ConnectorListeners()) def test_read(self): data = [] self.assertEqual(self._con.read(data),OpenRTM_aist.DataPortStatus.BUFFER_TIMEOUT) data = 123 self.assertEqual(self._con.read(data),OpenRTM_aist.DataPortStatus.BUFFER_TIMEOUT) return def test_disconnect(self): self.assertEqual(self._con.disconnect(),OpenRTM_aist.DataPortStatus.PORT_OK) return def test_activate(self): self._con.activate() return def test_deactivate(self): self._con.deactivate() return def test_createBuffer(self): self._con.createBuffer(OpenRTM_aist.ConnectorInfo("name","id",[],OpenRTM_aist.Properties())) return
class TestInPortPushConnector(unittest.TestCase): def setUp(self): OpenRTM_aist.Manager.instance() self._con = InPortPushConnector( OpenRTM_aist.ConnectorInfo("name", "id", [], OpenRTM_aist.Properties()), InPortProviderMock(), OpenRTM_aist.ConnectorListeners()) def test_read(self): data = [] self.assertEqual(self._con.read(data), OpenRTM_aist.DataPortStatus.BUFFER_TIMEOUT) data = 123 self.assertEqual(self._con.read(data), OpenRTM_aist.DataPortStatus.BUFFER_TIMEOUT) return def test_disconnect(self): self.assertEqual(self._con.disconnect(), OpenRTM_aist.DataPortStatus.PORT_OK) return def test_activate(self): self._con.activate() return def test_deactivate(self): self._con.deactivate() return def test_createBuffer(self): self._con.createBuffer( OpenRTM_aist.ConnectorInfo("name", "id", [], OpenRTM_aist.Properties())) return
def setUp(self): OpenRTM_aist.Manager.instance() self._con = InPortPushConnector(OpenRTM_aist.ConnectorInfo("name","id",[],OpenRTM_aist.Properties()),InPortProviderMock(),OpenRTM_aist.ConnectorListeners())
def setUp(self): OpenRTM_aist.Manager.instance() self._con = InPortPushConnector( OpenRTM_aist.ConnectorInfo("name", "id", [], OpenRTM_aist.Properties()), InPortProviderMock(), OpenRTM_aist.ConnectorListeners())