Add comprehensive test coverage across all modules #14

Merged
nrupard merged 1 commit from feat/more-tests into main 2026-03-17 20:36:20 +01:00
Member
  • Add unit tests for config (defaults, fields, banner, get_jwt_secret),
    db (schema creation, indexes, foreign keys, cleanup_old_clicks),
    auth/mod (get_claims), and auth/middleware (jwt_validator, admin_validator)
  • Expand handlers/pages tests to cover all static pages, serve_css,
    serve_auth_js, check_setup_required, and saas dashboard/refresh.js
  • Add integration test suite (tests/integration_standalone.rs) with 15
    end-to-end tests covering full user flows: register/login/shorten/redirect,
    stats, click history, URL lifecycle, QR codes, multi-user isolation,
    admin operations, token refresh, setup check, and abuse reporting
  • Fix 9 pre-existing SaaS test failures by using try_call_service for
    middleware error responses
  • Fix missing saas_refresh_url field in test config
  • Add lib.rs and [lib] target to support integration tests
  • Update Dockerfiles, compose.yml, and justfile for test infrastructure

Total: 173 standalone tests (158 unit + 15 integration), 92 SaaS tests

Co-Authored-By: Claude Opus 4.6 noreply@anthropic.com

- Add unit tests for config (defaults, fields, banner, get_jwt_secret), db (schema creation, indexes, foreign keys, cleanup_old_clicks), auth/mod (get_claims), and auth/middleware (jwt_validator, admin_validator) - Expand handlers/pages tests to cover all static pages, serve_css, serve_auth_js, check_setup_required, and saas dashboard/refresh.js - Add integration test suite (tests/integration_standalone.rs) with 15 end-to-end tests covering full user flows: register/login/shorten/redirect, stats, click history, URL lifecycle, QR codes, multi-user isolation, admin operations, token refresh, setup check, and abuse reporting - Fix 9 pre-existing SaaS test failures by using try_call_service for middleware error responses - Fix missing saas_refresh_url field in test config - Add lib.rs and [lib] target to support integration tests - Update Dockerfiles, compose.yml, and justfile for test infrastructure Total: 173 standalone tests (158 unit + 15 integration), 92 SaaS tests Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- Add unit tests for config (defaults, fields, banner, get_jwt_secret),
  db (schema creation, indexes, foreign keys, cleanup_old_clicks),
  auth/mod (get_claims), and auth/middleware (jwt_validator, admin_validator)
- Expand handlers/pages tests to cover all static pages, serve_css,
  serve_auth_js, check_setup_required, and saas dashboard/refresh.js
- Add integration test suite (tests/integration_standalone.rs) with 15
  end-to-end tests covering full user flows: register/login/shorten/redirect,
  stats, click history, URL lifecycle, QR codes, multi-user isolation,
  admin operations, token refresh, setup check, and abuse reporting
- Fix 9 pre-existing SaaS test failures by using try_call_service for
  middleware error responses
- Fix missing saas_refresh_url field in test config
- Add lib.rs and [lib] target to support integration tests
- Update Dockerfiles, compose.yml, and justfile for test infrastructure

Total: 173 standalone tests (158 unit + 15 integration), 92 SaaS tests

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
nrupard deleted branch feat/more-tests 2026-03-17 20:36:20 +01:00
Sign in to join this conversation.
No reviewers
No labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
a8n-tools/rus!14
No description provided.