Description
Write unit tests for backend/src/analytics/providers/track-event.provider.ts covering the happy path, an empty-data edge case, and a boundary date-range case, using mocked repositories.
Why this matters
The event tracking provider currently lacks dedicated test coverage, so a regression could ship undetected.
Files to touch
backend/src/analytics/providers/track-event.provider.spec.ts
Acceptance Criteria
Notes
This issue is part of the new analytics module effort (tracking, aggregation,
and reporting on player/game activity). Please keep new code inside
backend/src/analytics/ following the same module/controller/service/provider
layout used by existing modules (e.g. progress, streak, quests).
Description
Write unit tests for
backend/src/analytics/providers/track-event.provider.tscovering the happy path, an empty-data edge case, and a boundary date-range case, using mocked repositories.Why this matters
The event tracking provider currently lacks dedicated test coverage, so a regression could ship undetected.
Files to touch
backend/src/analytics/providers/track-event.provider.spec.tsAcceptance Criteria
npm testwith no manual setupNotes
This issue is part of the new
analyticsmodule effort (tracking, aggregation,and reporting on player/game activity). Please keep new code inside
backend/src/analytics/following the same module/controller/service/providerlayout used by existing modules (e.g.
progress,streak,quests).