arbret/backend/tests
counterweight 21698203fe
refactor(auth): unify authorization patterns with MANAGE_OWN_PROFILE permission
Issue #2: The profile route used a custom role-based check instead
of the permission-based pattern used everywhere else.

Changes:
- Add MANAGE_OWN_PROFILE permission to backend Permission enum
- Add permission to ROLE_REGULAR role definition
- Update profile routes to use require_permission(MANAGE_OWN_PROFILE)
- Remove custom require_regular_user dependency
- Update frontend Permission constant and profile page
- Update invites page to use permission instead of role check
- Update profile tests with proper permission mocking

This ensures consistent authorization patterns across all routes.
2025-12-21 23:50:06 +01:00
..
__init__.py with some tests 2025-12-18 21:48:41 +01:00
conftest.py refactor: make mock_enqueue_job fixture opt-in instead of autouse 2025-12-21 23:29:48 +01:00
helpers.py Add ruff linter/formatter for Python 2025-12-21 21:54:26 +01:00
test_auth.py Add ruff linter/formatter for Python 2025-12-21 21:54:26 +01:00
test_availability.py Add ruff linter/formatter for Python 2025-12-21 21:54:26 +01:00
test_booking.py Add ruff linter/formatter for Python 2025-12-21 21:54:26 +01:00
test_counter.py refactor: make mock_enqueue_job fixture opt-in instead of autouse 2025-12-21 23:29:48 +01:00
test_invites.py Add ruff linter/formatter for Python 2025-12-21 21:54:26 +01:00
test_jobs.py refactor: move process_random_number_job import to module level in tests 2025-12-21 23:25:31 +01:00
test_permissions.py refactor: make mock_enqueue_job fixture opt-in instead of autouse 2025-12-21 23:29:48 +01:00
test_profile.py refactor(auth): unify authorization patterns with MANAGE_OWN_PROFILE permission 2025-12-21 23:50:06 +01:00
test_validation.py Add ruff linter/formatter for Python 2025-12-21 21:54:26 +01:00