fix: doctor ignore install dir in legacy workspace check

This commit is contained in:
Peter Steinberger
2026-01-10 16:23:28 +01:00
parent db5e4b986b
commit e60c3fc1b3
4 changed files with 71 additions and 6 deletions

View File

@@ -535,8 +535,13 @@ describe("doctor", () => {
.mockReturnValue("/Users/steipete");
const realExists = fs.existsSync;
const legacyPath = path.join("/Users/steipete", "clawdis");
const legacyAgentsPath = path.join(legacyPath, "AGENTS.md");
const existsSpy = vi.spyOn(fs, "existsSync").mockImplementation((value) => {
if (value === "/Users/steipete/clawdis" || value === legacyPath)
if (
value === "/Users/steipete/clawdis" ||
value === legacyPath ||
value === legacyAgentsPath
)
return true;
return realExists(value as never);
});