mirror of
https://github.com/home-assistant/core.git
synced 2026-08-24 10:13:52 -05:00
Make sure we test latin-1 encoding in test
This commit is contained in:
@@ -23,7 +23,7 @@ TEST_CONFIG = {
|
||||
"auth_test": {
|
||||
"url": TEST_URL,
|
||||
"method": "get",
|
||||
"username": "test",
|
||||
"username": "tøst",
|
||||
"password": "123456",
|
||||
},
|
||||
}
|
||||
|
||||
@@ -125,7 +125,7 @@ async def test_rest_command_auth(
|
||||
|
||||
assert len(aioclient_mock.mock_calls) == 1
|
||||
_method, _url, _data, headers = aioclient_mock.mock_calls[0]
|
||||
encoded = base64.b64encode(b"test:123456").decode()
|
||||
encoded = base64.b64encode("tøst:123456".encode("latin-1")).decode()
|
||||
assert CIMultiDict(headers).getall("Authorization") == [f"Basic {encoded}"]
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user