Add and use HTTP_FORBIDDEN constant (#33839)
This commit is contained in:
1 parent
70ee9d7f26
commit
bc26be3c11
15 files changed
+60
-37
No files matched your search
@@ -8,6 +8,7 @@ from homeassistant.components.media_player.const import (
|
||||
SERVICE_PLAY_MEDIA,
|
||||
)
|
||||
import homeassistant.components.tts as tts
|
||||
from homeassistant.const import HTTP_FORBIDDEN
|
||||
from homeassistant.setup import setup_component
|
||||
|
||||
from tests.common import assert_setup_component, get_test_home_assistant, mock_service
|
||||
@@ -198,7 +199,7 @@ class TestTTSYandexPlatform:
|
||||
"speed": 1,
|
||||
}
|
||||
aioclient_mock.get(
|
||||
self._base_url, status=403, content=b"test", params=url_param
|
||||
self._base_url, status=HTTP_FORBIDDEN, content=b"test", params=url_param
|
||||
)
|
||||
|
||||
config = {tts.DOMAIN: {"platform": "yandextts", "api_key": "1234567xx"}}
|
||||
|
||||
Reference in new issue
Block a user