Files
ruflo/v2/scripts/test-swarm-integration.sh
T
rUvandClaude Opus 4.5 1b6a1971f7 feat(v3): add comprehensive v3 implementation plans and swarm architecture
- Reorganize v3/ into implementation/ subfolders:
  - planning/, architecture/, migration/, integration/
  - security/, adrs/, research/, swarm-plans/

- Add 15-agent concurrent swarm implementation plans:
  - SWARM-OVERVIEW.md: Hierarchical mesh topology, 4 phases
  - AGENT-SPECIFICATIONS.md: 15 agent configs with capabilities
  - TDD-LONDON-SCHOOL-PLAN.md: Mock-first TDD methodology
  - BENCHMARK-OPTIMIZATION.md: Performance targets (2.49x-7.47x)
  - DEPLOYMENT-PLAN.md: Release strategy, CI/CD, rollback
  - GITHUB-ISSUE-TRACKING.md: Issue workflow with agent replies

- Update .claude/settings.json with proper hooks format
- Add bash aliases for claude --dangerously-skip-permissions

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-04 15:40:51 +00:00

92 lines
2.7 KiB
Bash
Executable File

#!/bin/bash
# Integration test for Claude-Flow Swarm Mode
echo "Claude-Flow Swarm Mode Integration Test"
echo "======================================="
echo
# Test 1: Binary exists
echo "Test 1: Checking binary files..."
if [ -f "./bin/claude-flow" ]; then
echo "✅ claude-flow binary found"
else
echo "❌ claude-flow binary not found"
exit 1
fi
if [ -f "./bin/claude-flow-swarm" ]; then
echo "✅ claude-flow-swarm wrapper found"
else
echo "❌ claude-flow-swarm wrapper not found"
exit 1
fi
# Test 2: Help command
echo -e "\nTest 2: Testing help command..."
if ./bin/claude-flow help swarm | grep -q "Claude Swarm Mode"; then
echo "✅ Swarm help command works"
else
echo "❌ Swarm help command failed"
exit 1
fi
# Test 3: Swarm listed in main help
echo -e "\nTest 3: Checking swarm in main help..."
if ./bin/claude-flow --help | grep -q "swarm"; then
echo "✅ Swarm command listed in main help"
else
echo "❌ Swarm command not listed in main help"
exit 1
fi
# Test 4: Standalone swarm dry-run
echo -e "\nTest 4: Testing standalone swarm dry-run..."
if ./bin/claude-flow-swarm "Test objective" --dry-run | grep -q "DRY RUN"; then
echo "✅ Standalone swarm dry-run works"
else
echo "❌ Standalone swarm dry-run failed"
exit 1
fi
# Test 5: Complex swarm configuration
echo -e "\nTest 5: Testing complex swarm configuration..."
OUTPUT=$(./bin/claude-flow-swarm "Complex test" --strategy research --max-agents 10 --coordinator --review --parallel --dry-run)
if echo "$OUTPUT" | grep -q "Strategy: research" && \
echo "$OUTPUT" | grep -q "Max Agents: 10" && \
echo "$OUTPUT" | grep -q "Coordinator: true" && \
echo "$OUTPUT" | grep -q "Review Mode: true" && \
echo "$OUTPUT" | grep -q "Parallel: true"; then
echo "✅ Complex swarm configuration works"
else
echo "❌ Complex swarm configuration failed"
echo "Output: $OUTPUT"
exit 1
fi
# Test 6: Check documentation files
echo -e "\nTest 6: Checking documentation..."
if [ -f "./docs/12-swarm.md" ]; then
echo "✅ Swarm documentation found"
else
echo "❌ Swarm documentation not found"
exit 1
fi
# Test 7: Check swarm demo script
echo -e "\nTest 7: Checking swarm demo script..."
if [ -f "./swarm-demo.ts" ]; then
echo "✅ swarm-demo.ts found"
else
echo "❌ swarm-demo.ts not found"
exit 1
fi
echo -e "\n======================================="
echo "✅ All integration tests passed!"
echo
echo "Swarm mode is ready to use:"
echo " 1. ./bin/claude-flow swarm \"Your objective\" [options]"
echo " 2. ./bin/claude-flow-swarm \"Your objective\" [options]"
echo " 3. npx claude-flow swarm \"Your objective\" [options]"
echo
echo "For more info: ./bin/claude-flow help swarm"