mirror of
https://github.com/zulip/zulip.git
synced 2025-11-03 13:33:24 +00:00
users: Remove unnecessary get_api_key helper.
Using the column name is clearer.
This commit is contained in:
committed by
Tim Abbott
parent
8804c1afaa
commit
a7d513e5ec
@@ -11,7 +11,6 @@ from zerver.lib.exceptions import InvalidJSONError, JsonableError
|
||||
from zerver.lib.send_email import FromAddress
|
||||
from zerver.lib.test_classes import WebhookTestCase, ZulipTestCase
|
||||
from zerver.lib.test_helpers import HostRequestMock
|
||||
from zerver.lib.users import get_api_key
|
||||
from zerver.lib.webhooks.common import (
|
||||
INVALID_JSON_MESSAGE,
|
||||
MISSING_EVENT_HEADER_MESSAGE,
|
||||
@@ -74,7 +73,7 @@ class WebhooksCommonTestCase(ZulipTestCase):
|
||||
webhook_bot_email = "webhook-bot@zulip.com"
|
||||
webhook_bot_realm = get_realm("zulip")
|
||||
webhook_bot = get_user(webhook_bot_email, webhook_bot_realm)
|
||||
webhook_bot_api_key = get_api_key(webhook_bot)
|
||||
webhook_bot_api_key = webhook_bot.api_key
|
||||
request = HostRequestMock()
|
||||
request.POST["api_key"] = webhook_bot_api_key
|
||||
request.host = "zulip.testserver"
|
||||
|
||||
Reference in New Issue
Block a user