mirror of
https://github.com/bsedin/matrix-webhook.git
synced 2026-04-09 03:15:40 +00:00
lint: fix line length
This commit is contained in:
@@ -51,7 +51,8 @@ def wait_available(url: str, key: str, timeout: int = 10) -> bool:
|
||||
"""Wait until a service answer correctly or timeout."""
|
||||
|
||||
def check_json(url: str, key: str) -> bool:
|
||||
"""Ensure a service at a given url answers with valid json containing a certain key."""
|
||||
"""Ensure a service at a given url answers
|
||||
with valid json containing a certain key."""
|
||||
try:
|
||||
data = httpx.get(url).json()
|
||||
return key in data
|
||||
|
||||
@@ -29,8 +29,8 @@ class BotTest(unittest.IsolatedAsyncioTestCase):
|
||||
bot_req({"body": 3}, KEY, params={"formatter": "wrong_formatter"}),
|
||||
{"status": 400, "ret": "Unknown formatter"},
|
||||
)
|
||||
# TODO: if the client from matrix_webhook has olm support, this won't be a 403 from synapse,
|
||||
# but a LocalProtocolError from matrix_webhook
|
||||
# TODO: if the client from matrix_webhook has olm support,
|
||||
# this won't be a 403 from synapse, but a LocalProtocolError from matrix_webhook
|
||||
self.assertEqual(
|
||||
bot_req({"body": 3}, KEY, "wrong_room"),
|
||||
{"status": 403, "ret": "Unknown room"},
|
||||
|
||||
Reference in New Issue
Block a user