Files
cim_summary/backend
admin e630ff744a test(01-02): add AlertEventModel unit tests
- Tests cover create (valid, default status active, explicit status, with details JSONB)
- Input validation (empty name, invalid alert_type, invalid status)
- Supabase error handling (throws descriptive message)
- findActive (all active, filtered by service, empty array)
- acknowledge (sets status+timestamp, throws on not found via PGRST116)
- resolve (sets status+timestamp, throws on not found)
- findRecentByService (found within window, null when absent — deduplication use case)
- deleteOlderThan (cutoff date, returns count)
- All 41 tests pass (14 HealthCheck + 19 AlertEvent + 8 existing)
2026-02-24 12:22:12 -05:00
..
2025-07-30 22:02:17 -04:00
2025-07-30 22:02:17 -04:00