Skip to content

Commit 56ea4f7

Browse files
committed
fixes tokens
1 parent 4d4351f commit 56ea4f7

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

services/web/server/tests/unit/with_dbs/03/test_users__tokens.py

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
from copy import deepcopy
1111
from http import HTTPStatus
1212
from itertools import repeat
13-
from uuid import UUID
13+
from typing import Any
1414

1515
import pytest
1616
from aiohttp.test_utils import TestClient
@@ -61,7 +61,7 @@ async def fake_tokens(
6161
logged_user: UserInfoDict,
6262
tokens_db_cleanup: None,
6363
faker: Faker,
64-
) -> list:
64+
) -> list[dict[str, Any]]:
6565
all_tokens = []
6666
assert client.app
6767

@@ -135,7 +135,7 @@ async def test_read_token(
135135
client: TestClient,
136136
logged_user: UserInfoDict,
137137
tokens_db_cleanup: None,
138-
fake_tokens,
138+
fake_tokens: list[dict[str, Any]],
139139
expected: HTTPStatus,
140140
):
141141
assert client.app
@@ -157,7 +157,7 @@ async def test_read_token(
157157

158158
data, error = await assert_status(resp, expected)
159159

160-
expected_token["token_key"] = f'{UUID(expected_token["token_key"])}'
160+
expected_token["token_key"] = expected_token["token_key"]
161161
expected_token["token_secret"] = None
162162
assert data == expected_token, "list and read item are both read operations"
163163

@@ -175,7 +175,7 @@ async def test_delete_token(
175175
client: TestClient,
176176
logged_user: UserInfoDict,
177177
tokens_db_cleanup: None,
178-
fake_tokens: list,
178+
fake_tokens: list[dict[str, Any]],
179179
expected: HTTPStatus,
180180
):
181181
assert client.app

0 commit comments

Comments
 (0)