def build_multi_enb_magma_service(cls) -> MagmaService: event_loop = asyncio.get_event_loop() mconfig = EnodebConfigBuilder.get_multi_enb_mconfig() service_config = EnodebConfigBuilder.get_service_config() with mock.patch('magma.common.service.MagmaService') as MockService: MockService.config = service_config MockService.mconfig = mconfig MockService.loop = event_loop return MockService
def build_magma_service( cls, device: EnodebDeviceName = EnodebDeviceName.BAICELLS, ) -> MagmaService: event_loop = asyncio.get_event_loop() mconfig = EnodebConfigBuilder.get_mconfig(device) service_config = EnodebConfigBuilder.get_service_config() with mock.patch('magma.common.service.MagmaService') as MockService: MockService.config = service_config MockService.mconfig = mconfig MockService.loop = event_loop return MockService
def setUp(self) -> None: service = EnodebConfigBuilder.get_service_config() self.enb_acs_manager = StateMachineManager(service) self.mgr = StatsManager(self.enb_acs_manager) self.is_clear_stats_called = False