exafunction--windsurf-demo
59bf8ec387
- Fix calculateCenterOfMass test expectation (7.5 instead of 5) - Add comprehensive tests for getRandomPosition function - Add extensive tests for findSafeSpawnLocation covering: - Safe positioning away from AI players - Safe positioning away from player cells - Combined AI and player cell avoidance - Fallback logic when no safe spot found - Custom minDistance parameter handling - Empty game state handling - Mock-based retry logic testing - Import WORLD_SIZE constant for boundary testing - Achieve 95.55% statement coverage, 90.9% branch coverage, 100% function coverage