test(git-status): real-git rename and conflict diffs, tree setting round-trip

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01JrzFKEdBLwVfu6ev2ZscJS
This commit is contained in:
Devvyn
2026-10-05 09:57:30 +08:00
co-authored by Claude Sonnet 5.5
parent 58b52fceff
commit b2423c90ce
2 changed files with 42 additions and 0 deletions
+4
View File
@@ -264,6 +264,10 @@ describe('Git status indicator in a real browser', () => {
await page.evaluate(() => (window as any).app.saveAppSettings());
await page.waitForTimeout(300);
await page.evaluate(() => (window as any).app.closeAppSettings());
// gitStatusTree is per-device: it must never reach the strict PUT /api/settings (a 400 there is
// what an unstripped key looks like), and it must round-trip through the saved settings.
expect(settingsPutStatuses.every((st) => st === 200)).toBe(true);
expect(await page.evaluate(() => (window as any).app.isGitStatusTree())).toBe(true);
rmSync(join(repo, 'deep'), { recursive: true });
rmSync(join(repo, 'docs'), { recursive: true });
}, 30000);