Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitaly.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPatrick Steinhardt <psteinhardt@gitlab.com>2022-07-18 13:33:46 +0300
committerPatrick Steinhardt <psteinhardt@gitlab.com>2022-07-20 07:39:11 +0300
commit517bed409397bc928a85fc128e5e81e4880b6136 (patch)
treeefedc8907eb71b9c98ebafdd9906cf939b3f7a76 /internal/gitaly/service/operations/submodules_test.go
parent600197debaadea93b7b36f43e93493fc5fdc6946 (diff)
git: Move `ZeroOID` into `ObjectHash` structure
Move the `ZeroOID` variable into the `ObjectHash` structure to make it dependent on the hash function used.
Diffstat (limited to 'internal/gitaly/service/operations/submodules_test.go')
-rw-r--r--internal/gitaly/service/operations/submodules_test.go4
1 files changed, 2 insertions, 2 deletions
diff --git a/internal/gitaly/service/operations/submodules_test.go b/internal/gitaly/service/operations/submodules_test.go
index 9944c7801..442cc2964 100644
--- a/internal/gitaly/service/operations/submodules_test.go
+++ b/internal/gitaly/service/operations/submodules_test.go
@@ -32,14 +32,14 @@ func TestSuccessfulUserUpdateSubmoduleRequest(t *testing.T) {
// a branch which has a name starting with "refs/heads/".
currentOID, err := repo.ResolveRevision(ctx, "refs/heads/master")
require.NoError(t, err)
- require.NoError(t, repo.UpdateRef(ctx, "refs/heads/refs/heads/master", currentOID, git.ZeroOID))
+ require.NoError(t, repo.UpdateRef(ctx, "refs/heads/refs/heads/master", currentOID, git.ObjectHashSHA1.ZeroOID))
// If something uses the branch name as an unqualified reference, then
// git would return the tag instead of the branch. We thus create a tag
// with a different OID than the current master branch.
prevOID, err := repo.ResolveRevision(ctx, "refs/heads/master~")
require.NoError(t, err)
- require.NoError(t, repo.UpdateRef(ctx, "refs/tags/master", prevOID, git.ZeroOID))
+ require.NoError(t, repo.UpdateRef(ctx, "refs/tags/master", prevOID, git.ObjectHashSHA1.ZeroOID))
commitMessage := []byte("Update Submodule message")