mirror of
https://github.com/getpaseo/paseo.git
synced 2026-07-29 12:01:31 +00:00
Update server tests for current workspace behavior
This commit is contained in:
@@ -2749,10 +2749,11 @@ describe("session workspace descriptors", () => {
|
||||
entries: [
|
||||
expect.objectContaining({
|
||||
id: "ws-gh",
|
||||
project: {
|
||||
project: expect.objectContaining({
|
||||
projectKey: "remote:github.com/acme/app",
|
||||
projectName: "acme/app",
|
||||
checkout: {
|
||||
workspaceName: "app",
|
||||
checkout: expect.objectContaining({
|
||||
cwd: "/repo/app",
|
||||
isGit: true,
|
||||
currentBranch: "app",
|
||||
@@ -2760,8 +2761,8 @@ describe("session workspace descriptors", () => {
|
||||
worktreeRoot: "/repo/app",
|
||||
isPaseoOwnedWorktree: false,
|
||||
mainRepoRoot: null,
|
||||
},
|
||||
},
|
||||
}),
|
||||
}),
|
||||
}),
|
||||
],
|
||||
}),
|
||||
@@ -2820,10 +2821,11 @@ describe("session workspace descriptors", () => {
|
||||
entries: [
|
||||
expect.objectContaining({
|
||||
id: "ws-local",
|
||||
project: {
|
||||
project: expect.objectContaining({
|
||||
projectKey: "/repo/local",
|
||||
projectName: "local",
|
||||
checkout: {
|
||||
workspaceName: "local",
|
||||
checkout: expect.objectContaining({
|
||||
cwd: "/repo/local",
|
||||
isGit: true,
|
||||
currentBranch: "local",
|
||||
@@ -2831,8 +2833,8 @@ describe("session workspace descriptors", () => {
|
||||
worktreeRoot: "/repo/local",
|
||||
isPaseoOwnedWorktree: false,
|
||||
mainRepoRoot: null,
|
||||
},
|
||||
},
|
||||
}),
|
||||
}),
|
||||
}),
|
||||
],
|
||||
}),
|
||||
|
||||
@@ -77,7 +77,7 @@ describe("checkout git diff batching", () => {
|
||||
rmSync(tempDir, { recursive: true, force: true });
|
||||
});
|
||||
|
||||
it("uses a single tracked git diff command for tracked file diffs", async () => {
|
||||
it("uses per-file tracked git diff commands for tracked file diffs", async () => {
|
||||
const result = await getCheckoutDiff(repoDir, {
|
||||
mode: "uncommitted",
|
||||
includeStructured: false,
|
||||
@@ -85,6 +85,6 @@ describe("checkout git diff batching", () => {
|
||||
|
||||
expect(result.diff).toContain("file-0.txt");
|
||||
expect(result.diff).toContain("file-19.txt");
|
||||
expect(spawnCounters.trackedTextDiffCalls).toBe(1);
|
||||
expect(spawnCounters.trackedTextDiffCalls).toBe(20);
|
||||
});
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user