The fastest, cheapest, most efficient open-source agent harness. Run more than 500 agents on a $10 VPS.
Rust agent-orchestrationai-agentsai-assistantdesktopllmlocal-firstmcppersonal-aiprivacyrustsecond-braintauri
test(composerSendDecision): add tests for slash command routing
Steven Enamakel4802e34b7115
diff --git a/app/src/features/conversations/composerSendDecision.test.ts b/app/src/features/conversations/composerSendDecision.test.tsindex ff447d1dee..75872e23fa 100644--- a/app/src/features/conversations/composerSendDecision.test.ts+++ b/app/src/features/conversations/composerSendDecision.test.ts@@ -97,6 +97,19 @@ describe('handleComposerSlashCommand', () => {it('ignores normal chat text', () => {expect(handleComposerSlashCommand('hello')).toEqual({ kind: 'not_handled' });});++ it('maps /plan and /build to a run-mode switch', () => {+ expect(handleComposerSlashCommand('/plan')).toEqual({ kind: 'run_mode', mode: 'plan' });+ expect(handleComposerSlashCommand('/Build')).toEqual({ kind: 'run_mode', mode: 'build' });+ });++ it('maps /stop to cancelling the running turn', () => {+ expect(handleComposerSlashCommand('/stop')).toEqual({ kind: 'stop' });+ });++ it('does not treat a command followed by prose as the command', () => {+ expect(handleComposerSlashCommand('/plan the migration')).toEqual({ kind: 'not_handled' });+ });});describe('shouldSendComposerKeyDown', () => {