aboutsummaryrefslogtreecommitdiff
path: root/internal/testgit/repo_make_commit.go
diff options
context:
space:
mode:
authorGravatar Runxi Yu2026-02-20 22:59:14 +0800
committerGravatar Runxi Yu2026-02-20 22:59:14 +0800
commitd88c8e20aebd9408df0306e97dffc2896950342d (patch)
tree8e137f37fdd9ea673bd622a2b9c9873cd89278fb /internal/testgit/repo_make_commit.go
parentobjectid: Use _test package for tests (diff)
signatureNo signature
*: Replace repo with testRepo
Diffstat (limited to 'internal/testgit/repo_make_commit.go')
-rw-r--r--internal/testgit/repo_make_commit.go6
1 files changed, 3 insertions, 3 deletions
diff --git a/internal/testgit/repo_make_commit.go b/internal/testgit/repo_make_commit.go
index 35619334..a569dfb1 100644
--- a/internal/testgit/repo_make_commit.go
+++ b/internal/testgit/repo_make_commit.go
@@ -7,9 +7,9 @@ import (
)
// MakeCommit creates a commit over a single-file tree and returns (blobID, treeID, commitID).
-func (repo *TestRepo) MakeCommit(tb testing.TB, message string) (objectid.ObjectID, objectid.ObjectID, objectid.ObjectID) {
+func (testRepo *TestRepo) MakeCommit(tb testing.TB, message string) (objectid.ObjectID, objectid.ObjectID, objectid.ObjectID) {
tb.Helper()
- blobID, treeID := repo.MakeSingleFileTree(tb, "file.txt", []byte("commit-body\n"))
- commitID := repo.CommitTree(tb, treeID, message)
+ blobID, treeID := testRepo.MakeSingleFileTree(tb, "file.txt", []byte("commit-body\n"))
+ commitID := testRepo.CommitTree(tb, treeID, message)
return blobID, treeID, commitID
}