= MemoryMedium(discovery_class=MemoryDiscoveryMedium) medium.set_service(TestService('test_service', medium)) medium.start() return medium class ZeroMQMediumTestCase(_BaseMediumTestCase): def get_medium(self): medium = ZeroMQMedium(discovery_class=MemoryDiscoveryMedium) medium.set_service(TestService('test_service', medium)) medium.start() return medium
= MemoryMedium(loop=loop, discovery_class=MemoryDiscoveryMedium) medium.set_service(TestService('test_service', medium)) yield from medium.start() return medium class ZeroMQMediumTestCase(_BaseMediumTestCase): @asyncio.coroutine def get_medium(self, loop): medium = ZeroMQMedium(loop=loop, discovery_class=MemoryDiscoveryMedium) medium.set_service(TestService('test_service', medium)) yield from medium.start() return medium