Skip to content

Add unit tests for agent-types utility functions - #599

Merged
selfcontained merged 1 commit into
mainfrom
agt_20d829a05b1d/job-test-enforcer-948d008e
May 23, 2026
Merged

Add unit tests for agent-types utility functions#599
selfcontained merged 1 commit into
mainfrom
agt_20d829a05b1d/job-test-enforcer-948d008e

Conversation

@selfcontained

Copy link
Copy Markdown
Owner

Summary

  • Adds 25 unit tests for the four pure functions in apps/web/src/lib/agent-types.ts: isAgentType, isCliAgentType, sortAgentTypes, and sanitizeEnabledAgentTypes
  • Covers edge cases: invalid input types, empty arrays, deduplication, non-string entries, terminal sort ordering
  • Web test count: 70 → 95

Test plan

  • pnpm run check passes
  • pnpm run test passes (1289 server + 95 web)
  • pnpm run test:e2e passes (160 passed, 12 skipped)

🤖 Generated with Claude Code

Covers isAgentType, isCliAgentType, sortAgentTypes, and
sanitizeEnabledAgentTypes with 25 tests including edge cases
for invalid input, deduplication, empty arrays, and terminal
sort ordering.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@selfcontained
selfcontained merged commit 76c1c5d into mainMay 23, 2026
1 check passed
@selfcontained
selfcontained deleted the agt_20d829a05b1d/job-test-enforcer-948d008e branch May 23, 2026 02:20
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant

@selfcontained