Use HTTPStatus instead of HTTP_ consts and magic values in comp.../[bc]* (#57989)
This commit is contained in:
parent
ab7a34fc71
commit
73d192b3f3
25 changed files with 169 additions and 182 deletions
|
@ -1,4 +1,5 @@
|
|||
"""Tests for config/script."""
|
||||
from http import HTTPStatus
|
||||
from unittest.mock import patch
|
||||
|
||||
from homeassistant.bootstrap import async_setup_component
|
||||
|
@ -29,7 +30,7 @@ async def test_delete_script(hass, hass_client):
|
|||
):
|
||||
resp = await client.delete("/api/config/script/config/two")
|
||||
|
||||
assert resp.status == 200
|
||||
assert resp.status == HTTPStatus.OK
|
||||
result = await resp.json()
|
||||
assert result == {"result": "ok"}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue