d77eb4d55e
Add test support for default role assignment
2026-01-27 10:23:24 +01:00
ee50f312ee
Remove NoActor module, improve Member validation, update docs
2026-01-27 10:23:21 +01:00
da0b045771
Fix missing actor parameters and restore AshAuthentication bypass tests
2026-01-27 10:23:20 +01:00
31699b7c90
Fix rebase conflict: Add actor parameter to helper functions in index_test.exs
2026-01-27 10:23:20 +01:00
2d7461e36f
Use admin_user instead of system_actor in LiveView tests
2026-01-27 10:23:19 +01:00
aedd29c118
Fix tests: Remove redundant system_actor and update test descriptions
2026-01-27 10:23:18 +01:00
0e6b464e0a
Fix tests: Add missing actor parameters to Ash operations
2026-01-27 10:23:18 +01:00
f993c64c42
Fix test helpers: Use actor parameter correctly
2026-01-27 10:23:18 +01:00
875abc693b
Fix tests: Remove duplicate actor keyword arguments
2026-01-27 10:23:17 +01:00
c715a45277
Add actor parameter to all tests requiring authorization
...
This commit adds actor: system_actor to all Ash operations in tests that
require authorization.
2026-01-27 10:23:16 +01:00
ef4df57a6f
Restrict Actor.ensure_loaded to Mv.Accounts.User only
...
Pattern match on %Mv.Accounts.User{} instead of generic actor.
Clearer intention, prevents accidental authorization bypasses.
Non-User actors are returned as-is (no-op).
2026-01-27 10:23:13 +01:00
e6b22cff16
Remove skipped get_by_subject test, add explanation
...
Test removed - JWT flow tested via AshAuthentication integration.
Direct test would require JWT mocking without value.
2026-01-27 10:23:11 +01:00
69836978be
Remove unused PolicyHelpers macro and PolicyConsistency test
...
Dead code - macro was never used in codebase.
PolicyConsistency test will be replaced with better implementation.
2026-01-27 10:23:10 +01:00
213521ecf6
Add centralized Actor.ensure_loaded helper
...
Consolidate role loading logic from HasPermission and LiveHelpers.
Use Ash.Resource.Info.resource? for reliable Ash detection.
2026-01-27 10:23:10 +01:00
ab0407abb1
Replace NoActor runtime Mix.env with compile-time config
...
Use Application.compile_env for release-safety.
Config only set in test.exs (defaults to false).
2026-01-27 10:23:09 +01:00
d0c1996d6e
Add policy consistency tests
...
Enforce User.update :own across all permission sets.
Verify READ bypass + UPDATE HasPermission pattern.
2026-01-27 10:23:09 +01:00
28526deb9c
Replace for comprehension with explicit describe blocks
...
Fix Credo parsing error by removing for comprehension.
Duplicate tests for own_data, read_only, normal_user sets.
2026-01-27 10:23:08 +01:00
7eb7149e18
Add role loading fallback to HasPermission check
...
Extract ash_resource? helper to reduce nesting depth.
Add ensure_role_loaded fallback for unloaded actor roles.
2026-01-27 10:23:07 +01:00
298a13c2e4
Harden NoActor check with runtime environment guard
...
Add Mix.env() check to match?/3 for defense in depth.
Document NoActor pattern in CODE_GUIDELINES.md.
2026-01-27 10:23:06 +01:00
3ad0db0b2f
test(auth): add User policies test suite
...
31 tests covering all 4 permission sets and bypass scenarios
Update HasPermission tests to expect false for scope :own without record
2026-01-27 10:23:06 +01:00
38ae25e0e3
Refactor test setup into helper functions
...
Extract setup code into reusable helper functions to reduce
duplication and improve maintainability.
2026-01-27 10:14:05 +01:00
8eb05c8a6a
Document System Actor pattern in code guidelines
...
Add section explaining when and how to use system actor for systemic operations.
Include examples and distinction between user mode and system mode.
2026-01-27 10:14:04 +01:00
481e82d541
Add tests for System Actor helper
...
Test system actor retrieval, caching, fallback behavior,
and auto-creation in test environment.
2026-01-27 10:14:04 +01:00
0d244a4860
fix: resolve pr remarks
2026-01-27 10:14:01 +01:00
be29b46874
fix: credo warning
2026-01-27 10:14:00 +01:00
2dd5ef9926
test: add more filter component tests
2026-01-27 10:13:59 +01:00
ca1300f46a
feat: add new filter component to members view
2026-01-27 10:13:59 +01:00
7171e21a10
feat: load boolean custom fields
2026-01-27 10:13:59 +01:00
7f4c22d072
refactor: fix credo issues
2026-01-27 10:13:58 +01:00
d296418c8e
test: Remove outdated TODO for auto-assignment feature
...
Auto-assignment of default membership fee type is already implemented
via SetDefaultMembershipFeeType change. Test assertion is now active.
2026-01-27 10:13:57 +01:00
c137ee6221
refactor: Replace length/1 with empty list comparison
...
Replace expensive length/1 calls with direct list comparison
to fix Credo warnings about performance
2026-01-27 10:13:56 +01:00
a72896095a
test: Add tests for UserLive.Show and RoleLive.Show
...
- Add comprehensive tests for UserLive.Show
- Add comprehensive tests for RoleLive.Show
- Cover mount, display, navigation, and error handling
2026-01-27 10:13:55 +01:00
4154296b54
refactor: Remove deprecated LiveViews
...
- Remove CustomFieldValueLive (Index, Form, Show)
- Remove ContributionTypeLive.Index
- Remove ContributionPeriodLive.Show
- Remove corresponding routes from router
- Remove references in CustomFieldValueLive.Index
2026-01-27 10:13:55 +01:00
da9ec06e8e
feat: implement filter logic for boolean ustom fields
2026-01-27 10:13:53 +01:00
b701b84260
test: add tdd tests for custom boolean field filter logic
2026-01-27 10:13:53 +01:00
0519433644
feat: add custom boolean field state & URL-Parameter
2026-01-27 10:13:53 +01:00
f052b25213
test: add tdd tests for backend state management of boolean custom filters
2026-01-27 10:13:53 +01:00
d8ab9a1015
fix: linting + tests
2026-01-27 10:13:52 +01:00
a161393ea1
fix: change creation of admin user
2026-01-27 10:13:51 +01:00
3aa1aee11e
fix: add error message to form
2026-01-27 10:13:51 +01:00
257739d273
feat: adds error capping
2026-01-27 10:13:50 +01:00
24426c7786
Merge branch 'main' into feature/333_validation
2026-01-19 11:46:14 +01:00
7da037d81d
refactor: adds schemales changeset and validation constant
2026-01-19 11:43:51 +01:00
8b3cc6a6b2
feat: adds row validation
2026-01-19 11:22:11 +01:00
c86ae6aa9d
fix: sidebar accessibility
2026-01-16 14:17:15 +01:00
d6173571b5
test: make tests more structural, less dependend on specific values
2026-01-16 12:48:35 +01:00
6dc398fa5a
refactor: reduce complexity
2026-01-15 17:00:17 +01:00
0673684cc1
test: adds tests for header normalization
2026-01-15 16:11:02 +01:00
3bbe9895ee
fix: improve CSV parser error handling
2026-01-15 11:08:22 +01:00
31cf07c071
test: updated tests
2026-01-15 10:10:14 +01:00