Skip to content

Commit e08a526

Browse files
committed
Revert "feat(security): extending parameters for test_token to cover sequence for audience"
This reverts commit 256ac46.
1 parent cf4eba1 commit e08a526

File tree

1 file changed

+6
-27
lines changed

1 file changed

+6
-27
lines changed

tests/unit/test_security/test_jwt/test_token.py

Lines changed: 6 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -19,38 +19,17 @@
1919
from litestar.security.jwt.token import JWTDecodeOptions
2020

2121

22+
@pytest.mark.parametrize("algorithm", ["HS256", "HS384", "HS512"])
23+
@pytest.mark.parametrize("token_issuer", [None, "e3d7d10edbbc28bfebd8861d39ae7587acde1e1fcefe2cbbec686d235d68f475"])
24+
@pytest.mark.parametrize("token_audience", [None, "627224198b4245ed91cf8353e4ccdf1650728c7ee92748f55fe1e9a9c4d961df"])
2225
@pytest.mark.parametrize(
23-
"algorithm",
24-
[pytest.param("HS256", id="HS256"), pytest.param("HS384", id="HS384"), pytest.param("HS512", id="HS512")],
25-
)
26-
@pytest.mark.parametrize(
27-
"token_issuer",
28-
[
29-
pytest.param(None, id="None"),
30-
pytest.param("e3d7d10edbbc28bfebd8861d39ae7587acde1e1fcefe2cbbec686d235d68f475", id="String"),
31-
],
32-
)
33-
@pytest.mark.parametrize(
34-
"token_audience",
35-
[
36-
pytest.param(None, id="None"),
37-
pytest.param("627224198b4245ed91cf8353e4ccdf1650728c7ee92748f55fe1e9a9c4d961df", id="String"),
38-
],
39-
)
40-
@pytest.mark.parametrize(
41-
"token_unique_jwt_id",
42-
[
43-
pytest.param(None, id="None"),
44-
pytest.param("10f5c6967783ddd6bb0c4e8262d7097caeae64705e45f83275e3c32eee5d30f2", id="String"),
45-
],
46-
)
47-
@pytest.mark.parametrize(
48-
"token_extras", [pytest.param(None, id="None"), pytest.param({"email": "[email protected]"}, id="Dict")]
26+
"token_unique_jwt_id", [None, "10f5c6967783ddd6bb0c4e8262d7097caeae64705e45f83275e3c32eee5d30f2"]
4927
)
28+
@pytest.mark.parametrize("token_extras", [None, {"email": "[email protected]"}])
5029
def test_token(
5130
algorithm: str,
5231
token_issuer: str | None,
53-
token_audience: str | Sequence[str] | None,
32+
token_audience: str | None,
5433
token_unique_jwt_id: str | None,
5534
token_extras: dict[str, Any] | None,
5635
) -> None:

0 commit comments

Comments
 (0)