zulip_bots and zulip_botserver: Extract common function.

This commit is contained in:
dkvasov 2018-05-17 17:35:09 +03:00
parent 4244a82b03
commit a06fb98f21
3 changed files with 23 additions and 32 deletions

View file

@ -14,7 +14,7 @@ class BotServerTests(BotServerTestCase):
def handler_class(self) -> Any:
return BotServerTests.MockMessageHandler()
@mock.patch('zulip_botserver.server.ExternalBotHandler')
@mock.patch('zulip_bots.lib.ExternalBotHandler')
def test_successful_request(self, mock_ExternalBotHandler: mock.Mock) -> None:
available_bots = ['helloworld']
bots_config = {
@ -28,7 +28,7 @@ class BotServerTests(BotServerTestCase):
bots_config=bots_config,
check_success=True)
@mock.patch('zulip_botserver.server.ExternalBotHandler')
@mock.patch('zulip_bots.lib.ExternalBotHandler')
def test_successful_request_from_two_bots(self, mock_ExternalBotHandler: mock.Mock) -> None:
available_bots = ['helloworld', 'help']
bots_config = {