MCPcopy Create free account
hub / github.com/DeepL/deepl-python / test_invalid_auth_key

Function test_invalid_auth_key

tests/test_translate_text.py:368–373  ·  view source on GitHub ↗
(server)

Source from the content-addressed store, hash-verified

366
367
368def test_invalid_auth_key(server):
369 translator = deepl.Translator("invalid", server_url=server.server_url)
370 with pytest.raises(
371 deepl.AuthorizationException, match=r".*Authorization failure.*"
372 ):
373 translator.translate_text("Hello, world!", target_lang="DE")
374
375
376def test_empty_text(translator):

Callers

nothing calls this directly

Calls 1

translate_textMethod · 0.95

Tested by

no test coverage detected