功能补齐、查看git提交历史

This commit is contained in:
2026-06-12 09:21:37 +08:00
parent fba3a14367
commit 2a9661a6ef
12 changed files with 329 additions and 9 deletions
+8
View File
@@ -105,6 +105,14 @@ func (f *fakeGitOpsSvc) PushOnWorktree(_ context.Context, _ workspace.Caller, wt
f.lastTarget = "worktree:" + wtID.String()
return nil
}
func (f *fakeGitOpsSvc) LogOnMain(_ context.Context, _ workspace.Caller, wsID uuid.UUID, _ int) ([]git.Commit, error) {
f.lastTarget = "main:" + wsID.String()
return nil, nil
}
func (f *fakeGitOpsSvc) LogOnWorktree(_ context.Context, _ workspace.Caller, wtID uuid.UUID, _ int) ([]git.Commit, error) {
f.lastTarget = "worktree:" + wtID.String()
return nil, nil
}
// wsTestDeps 在 testDeps 基础上挂一个已存在的 workspace + worktree 服务。
func wsTestDeps() (ServerDeps, *fakeWorkspaceSvc, *fakeWorktreeSvc, *fakeGitOpsSvc) {