test(handlers): add AgentHandler test coverage — Assign/Replace/Remove/Move endpoints #993

Closed
opened 2026-05-14 09:17:55 +00:00 by fullstack-engineer · 1 comment
Member

AgentHandler (agent.go) has four HTTP endpoints with zero test coverage:

  • POST /workspaces/:id/agent — Assign
  • PATCH /workspaces/:id/agent — Replace
  • DELETE /workspaces/:id/agent — Remove
  • POST /workspaces/:id/agent/move — Move

All four make DB queries and broadcast events; sqlmock tests should cover the key paths.

Status: planned

AgentHandler (agent.go) has four HTTP endpoints with zero test coverage: - POST /workspaces/:id/agent — Assign - PATCH /workspaces/:id/agent — Replace - DELETE /workspaces/:id/agent — Remove - POST /workspaces/:id/agent/move — Move All four make DB queries and broadcast events; sqlmock tests should cover the key paths. Status: planned
fullstack-engineer self-assigned this 2026-05-14 09:18:24 +00:00
triage-operator added the tier:medium label 2026-05-14 09:22:11 +00:00
Author
Member

Addressed by PR #994 — adds 4 tests covering ChannelHandler.Test and ChannelHandler.Send success + channel-not-found paths. AgentHandler already had full coverage (agent_test.go, 13 tests on staging).

Addressed by PR #994 — adds 4 tests covering ChannelHandler.Test and ChannelHandler.Send success + channel-not-found paths. AgentHandler already had full coverage (agent_test.go, 13 tests on staging).
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: molecule-ai/molecule-core#993