You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
test: add unit tests for all badges and CI workflow on badge changes #546
PR #545 introduced the first unit test (tests/badges.test.cjs) covering the SPRINTER badge. We should expand this to cover all 8 badges with positive and negative cases, and gate merges with a CI check.
Badges Needing Tests
HOT_STREAK — earned when data.streak.current >= 7, locked otherwise
HARD_CARRY — earned when 5+ Hard and 0 Easy solved in most recent 7-day window
CENTURION — earned when total solved (easy + medium + hard) ≥ 100
BALANCED — earned when each ≥ 5 and max-min within 5% of max
UP_LINK — earned when ranks.overall.change >= 5
TOP_BRASS — earned when ranks.overall.rank <= 10 (excluding --)
SPEEDRUN — earned when ranks.weekly.rank <= 3 and positive weighted score
Activity
YashBora21 commentedon Oct 14, 2026
@jagdish-15 , I’d like to take this follow-up issue and add tests for the remaining badges plus the CI workflow. Could you assign #546 to me