mirror of
https://github.com/home-assistant/core.git
synced 2025-12-24 21:06:19 +00:00
OAuth2 to use current request header (#43668)
This commit is contained in:
@@ -71,7 +71,13 @@ async def test_config_reauth_profile(
|
||||
)
|
||||
|
||||
# pylint: disable=protected-access
|
||||
state = config_entry_oauth2_flow._encode_jwt(hass, {"flow_id": result["flow_id"]})
|
||||
state = config_entry_oauth2_flow._encode_jwt(
|
||||
hass,
|
||||
{
|
||||
"flow_id": result["flow_id"],
|
||||
"redirect_uri": "https://example.com/auth/external/callback",
|
||||
},
|
||||
)
|
||||
|
||||
client: TestClient = await aiohttp_client(hass.http.app)
|
||||
resp = await client.get(f"{AUTH_CALLBACK_PATH}?code=abcd&state={state}")
|
||||
|
||||
Reference in New Issue
Block a user