예제 #1
0
 async def test_closes_spawner_on_close(self) -> None:
     companion_manager = CompanionManager(companion_path=None,
                                          logger=mock.MagicMock())
     spawner = mock.Mock()
     companion_manager.companion_spawner = spawner
     companion_manager.channel = mock.Mock()
     companion_manager.close()
     spawner.close.assert_called_once()
예제 #2
0
 async def test_closes_spawner_on_close(self) -> None:
     companion_manager = CompanionManager(companion_path=None,
                                          logger=mock.MagicMock())
     spawner = mock.Mock()
     companion_manager.companion_spawner = spawner
     # pyre-fixme[16]: `CompanionManager` has no attribute `channel`.
     companion_manager.channel = mock.Mock()
     companion_manager.close()
     spawner.close.assert_called_once()