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:
authorAhmad Sherif <me@ahmadsherif.com>2017-08-25 22:00:59 +0300
committerAhmad Sherif <me@ahmadsherif.com>2017-08-25 22:01:55 +0300
commit838afd2d0a56b69277d57da296876c320b8a415b (patch)
tree89adaf0257e00df1a2f01e30f1d397938d078bb7 /internal/testhelper
parent2c14d75b153dbf089ec88e616767ea9abf02be15 (diff)
Retire CommitsEqual in favor of require.Equal
The latter does a better job at diffing.
Diffstat (limited to 'internal/testhelper')
-rw-r--r--internal/testhelper/testhelper.go15
1 files changed, 0 insertions, 15 deletions
diff --git a/internal/testhelper/testhelper.go b/internal/testhelper/testhelper.go
index 00404ead1..3712b4aa9 100644
--- a/internal/testhelper/testhelper.go
+++ b/internal/testhelper/testhelper.go
@@ -8,7 +8,6 @@ import (
"os/exec"
"path"
"path/filepath"
- "reflect"
"runtime"
"strings"
"testing"
@@ -135,20 +134,6 @@ func AuthorsEqual(a *pb.CommitAuthor, b *pb.CommitAuthor) bool {
a.Date.Seconds == b.Date.Seconds
}
-// CommitsEqual tests if two `GitCommit`s are equal
-func CommitsEqual(a *pb.GitCommit, b *pb.GitCommit) bool {
- if a == nil || b == nil {
- return a == b
- }
-
- return a.Id == b.Id &&
- bytes.Equal(a.Subject, b.Subject) &&
- bytes.Equal(a.Body, b.Body) &&
- AuthorsEqual(a.Author, b.Author) &&
- AuthorsEqual(a.Committer, b.Committer) &&
- reflect.DeepEqual(a.ParentIds, b.ParentIds)
-}
-
// FindLocalBranchCommitAuthorsEqual tests if two `FindLocalBranchCommitAuthor`s are equal
func FindLocalBranchCommitAuthorsEqual(a *pb.FindLocalBranchCommitAuthor, b *pb.FindLocalBranchCommitAuthor) bool {
return bytes.Equal(a.Name, b.Name) &&