DIFF-452:AI NeedsRepair 与卸载保留用户 Skill 文件
背景
Electron repairs a moved runtime and missing files, then removes only managed content 覆盖 runtime 迁移后的 needs-repair、缺 Skill 重装,以及卸载时保留用户自定义资源。Compose 状态机已支持,但缺可模拟 launch 变更的测试。
行为
AiIntegrationService.testLaunch:测试覆盖McpLaunchResolver.clientLaunch(模拟安装后 runtime 参数变化)。mcpNeedsRepairWhenRuntimeLaunchChangesAndReinstallFixes:旧 launch 安装 → 新 launch →NeedsRepair→ 重装恢复Installed。codexSkillNeedsRepairWhenManagedFileMissing:删除SKILL.md→NeedsRepair→Both重装。uninstallPreservesUserFilesInSkillDirectory:卸载移除托管SKILL.md与 MCP 段,保留my-resource.txt与用户 TOML 注释前缀。
验证
./gradlew :composeApp:desktopTest --offline(605/605)