From ce44bc65c1d6e413422ceb124bda3e953a336ab2 Mon Sep 17 00:00:00 2001 From: Pavel Tisnovsky Date: Sun, 10 Aug 2025 09:54:56 +0200 Subject: [PATCH] Better docstring for auth no-op unit test --- tests/unit/auth/test_noop_with_token.py | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/tests/unit/auth/test_noop_with_token.py b/tests/unit/auth/test_noop_with_token.py index 0ed460b2..4c3bc77e 100644 --- a/tests/unit/auth/test_noop_with_token.py +++ b/tests/unit/auth/test_noop_with_token.py @@ -55,7 +55,15 @@ async def test_noop_with_token_auth_dependency_custom_user_id(): async def test_noop_with_token_auth_dependency_no_token(): - """Test the NoopWithTokenAuthDependency class with no token.""" + """ + Test if checks for Authorization header is in place. + + Test that NoopWithTokenAuthDependency raises an HTTPException when no + Authorization header is present in the request. + + Asserts that the exception has a status code of 400 and the detail message + "No Authorization header found". + """ dependency = NoopWithTokenAuthDependency() # Create a mock request without token