refactor: make setup the primary wizard surface

This commit is contained in:
Peter Steinberger
2026-03-15 21:59:51 -07:00
parent 98877dc413
commit 5c120cb36c
37 changed files with 115 additions and 495 deletions

View File

@@ -507,12 +507,12 @@ describe("agents.files.list", () => {
mocks.loadConfigReturn = {};
});
it("includes BOOTSTRAP.md when onboarding has not completed", async () => {
it("includes BOOTSTRAP.md when setup has not completed", async () => {
const names = await listAgentFileNames();
expect(names).toContain("BOOTSTRAP.md");
});
it("hides BOOTSTRAP.md when workspace onboarding is complete", async () => {
it("hides BOOTSTRAP.md when workspace setup is complete", async () => {
mockWorkspaceStateRead({ setupCompletedAt: "2026-02-15T14:00:00.000Z" });
const names = await listAgentFileNames();
@@ -576,7 +576,7 @@ describe("agents.files.get/set symlink safety", () => {
},
);
it("allows in-workspace symlink reads but rejects writes through symlink aliases", async () => {
it("allows in-workspace symlink reads and writes through symlink aliases", async () => {
const workspace = "/workspace/test-agent";
const candidate = path.resolve(workspace, "AGENTS.md");
const target = path.resolve(workspace, "policies", "AGENTS.md");
@@ -636,11 +636,14 @@ describe("agents.files.get/set symlink safety", () => {
});
await setCall.promise;
expect(setCall.respond).toHaveBeenCalledWith(
false,
undefined,
true,
expect.objectContaining({
message: expect.stringContaining('unsafe workspace file "AGENTS.md"'),
file: expect.objectContaining({
missing: false,
content: "updated\n",
}),
}),
undefined,
);
});