strat-gameplay-webapp/backend/tests/unit/core
Cal Corum cf7cc23f45 CLAUDE: Fix runner_advancement for new GameState structure
Updated runner_advancement.py and its tests to use the new GameState
structure where current_batter is a LineupPlayerState object instead of
an integer ID.

Changes:
- runner_advancement.py: Replaced all 17 references to
  state.current_batter_lineup_id with state.current_batter.lineup_id

- tests/unit/core/test_runner_advancement.py: Updated test fixtures
  - Mock fixture: Added mock_batter object with lineup_id attribute
  - GameState constructor calls: Create LineupPlayerState objects instead
    of using current_batter_lineup_id parameter (9 tests fixed)

All 34 runner advancement tests now passing. This fixes the AttributeError
that was preventing X-Check resolution from completing in the terminal
client ("'GameState' object has no attribute 'current_batter_lineup_id'").

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

Co-Authored-By: Claude <noreply@anthropic.com>
2025-11-04 16:03:46 -06:00
..
__init__.py CLAUDE: Complete Week 4 - State Management & Persistence 2025-10-22 12:01:03 -05:00
test_dice.py CLAUDE: Complete Week 6 - granular PlayOutcome integration and metadata support 2025-10-29 20:29:06 -05:00
test_flyball_advancement.py CLAUDE: Integrate flyball advancement with RunnerAdvancement system 2025-10-31 17:04:23 -05:00
test_play_resolver.py CLAUDE: Update tests to match Phase 2 model changes 2025-10-31 16:11:39 -05:00
test_roll_types.py CLAUDE: Complete Week 6 - granular PlayOutcome integration and metadata support 2025-10-29 20:29:06 -05:00
test_runner_advancement.py CLAUDE: Fix runner_advancement for new GameState structure 2025-11-04 16:03:46 -06:00
test_state_manager.py CLAUDE: Fix game recovery for new GameState structure 2025-11-04 15:26:00 -06:00
test_validators.py CLAUDE: Update tests to match Phase 2 model changes 2025-10-31 16:11:39 -05:00
test_x_check_advancement_tables.py CLAUDE: Integrate X-Check advancement with full GameState support 2025-11-03 00:21:52 -06:00