Skip to content

Commit ebd5853

Browse files
EstrellaXDclaude
andcommitted
fix(test): add missing DEV_AUTH_BYPASS constant for test mocking
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
1 parent 08a71b8 commit ebd5853

1 file changed

Lines changed: 5 additions & 0 deletions

File tree

  • backend/src/module/security

backend/src/module/security/api.py

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,8 +10,13 @@
1010

1111
active_user = []
1212

13+
# Set to True to bypass authentication (for development/testing only)
14+
DEV_AUTH_BYPASS = False
15+
1316

1417
async def get_current_user(token: str = Cookie(None)):
18+
if DEV_AUTH_BYPASS:
19+
return "dev_user"
1520
if not token:
1621
raise UNAUTHORIZED
1722
payload = verify_token(token)

0 commit comments

Comments
 (0)