Finance-Accounts/ar-aging-app/backend/tests
Talha Ahmed 2aed450f4c Password updates via emailed 6-digit code
New flow (active once AR_SMTP_* is configured; hidden otherwise):
- POST /api/auth/request-code emails a code to the account address
  (usernames are emails). HMAC-stored, 10-min expiry, single-use,
  5-attempt lockout, 60s resend throttle, no user enumeration.
- POST /api/auth/reset-password sets the new password with the code —
  works signed-in (Settings) and from the login screen (Forgot
  password?), so users can self-recover without the admin.
- Mailer: stdlib smtplib (STARTTLS/SSL, certifi CA bundle); SMTP
  settings documented in .env templates.
- Settings switches to the code flow when email is on; the
  current-password form remains the fallback.

Note: CRAI_Report was checked as the reference for code-sending — it
has no email/OTP functionality, so this is a fresh implementation.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
2026-08-19 19:35:07 +05:00
..
__init__.py Initial commit: AR aging app with root gitignore. 2026-07-29 18:07:21 +05:00
conftest.py New 2026-08-04 11:41:50 +05:00
test_aging.py Enhance API functionality and session management 2026-08-03 11:38:48 +05:00
test_api.py Production readiness: month separation, auth, FX service, AWS deployment 2026-08-19 18:46:47 +05:00
test_auth.py Password updates via emailed 6-digit code 2026-08-19 19:35:07 +05:00
test_controls.py Enhance API functionality and session management 2026-08-03 11:38:48 +05:00
test_csv_reader.py fix isuses 2026-08-18 19:37:57 +05:00
test_engine_unit.py Initial commit: AR aging app with root gitignore. 2026-07-29 18:07:21 +05:00
test_excel_export.py New 2026-08-04 11:41:50 +05:00
test_frontend_guards.py Production readiness: month separation, auth, FX service, AWS deployment 2026-08-19 18:46:47 +05:00
test_fx_dashboard.py fix isuses 2026-08-18 19:37:57 +05:00
test_fx_service.py Production readiness: month separation, auth, FX service, AWS deployment 2026-08-19 18:46:47 +05:00
test_month_locking.py Production readiness: month separation, auth, FX service, AWS deployment 2026-08-19 18:46:47 +05:00
test_multimarket.py Initial commit: AR aging app with root gitignore. 2026-07-29 18:07:21 +05:00
test_payout_receipts.py Production readiness: month separation, auth, FX service, AWS deployment 2026-08-19 18:46:47 +05:00
test_per_market.py Production readiness: month separation, auth, FX service, AWS deployment 2026-08-19 18:46:47 +05:00
test_reader_equivalence.py Enhance API functionality and session management 2026-08-03 11:38:48 +05:00
test_reconciliation_jan2026.py Initial commit: AR aging app with root gitignore. 2026-07-29 18:07:21 +05:00
test_robustness.py Initial commit: AR aging app with root gitignore. 2026-07-29 18:07:21 +05:00
test_session_lifecycle.py Production readiness: month separation, auth, FX service, AWS deployment 2026-08-19 18:46:47 +05:00
test_summary_export.py Enhance API functionality and session management 2026-08-03 11:38:48 +05:00
test_upload_dedup.py Production readiness: month separation, auth, FX service, AWS deployment 2026-08-19 18:46:47 +05:00
test_workbook_comparison.py Initial commit: AR aging app with root gitignore. 2026-07-29 18:07:21 +05:00