mirror of
https://github.com/home-assistant/core.git
synced 2025-07-23 13:17:32 +00:00
Prevent opening of sockets in onboarding tests (#56443)
This commit is contained in:
parent
a54854d129
commit
5c717cbb1d
@ -325,10 +325,16 @@ async def test_onboarding_integration_invalid_redirect_uri(
|
|||||||
|
|
||||||
client = await hass_client()
|
client = await hass_client()
|
||||||
|
|
||||||
resp = await client.post(
|
with patch(
|
||||||
"/api/onboarding/integration",
|
"homeassistant.components.auth.indieauth.fetch_redirect_uris", return_value=[]
|
||||||
json={"client_id": CLIENT_ID, "redirect_uri": "http://invalid-redirect.uri"},
|
):
|
||||||
)
|
resp = await client.post(
|
||||||
|
"/api/onboarding/integration",
|
||||||
|
json={
|
||||||
|
"client_id": CLIENT_ID,
|
||||||
|
"redirect_uri": "http://invalid-redirect.uri",
|
||||||
|
},
|
||||||
|
)
|
||||||
|
|
||||||
assert resp.status == 400
|
assert resp.status == 400
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user