diff options
Diffstat (limited to 'plumbing')
-rw-r--r-- | plumbing/object/commit_walker_bfs_filtered_test.go | 10 |
1 files changed, 2 insertions, 8 deletions
diff --git a/plumbing/object/commit_walker_bfs_filtered_test.go b/plumbing/object/commit_walker_bfs_filtered_test.go index d31bdf0..6984b60 100644 --- a/plumbing/object/commit_walker_bfs_filtered_test.go +++ b/plumbing/object/commit_walker_bfs_filtered_test.go @@ -29,9 +29,7 @@ func commitsFromIter(iter CommitIter) ([]*Commit, error) { func assertHashes(c *C, commits []*Commit, hashes []string) { if len(commits) != len(hashes) { var expected []string - for _, c := range hashes { - expected = append(expected, c) - } + expected = append(expected, hashes...) fmt.Println("expected:", strings.Join(expected, ", ")) var got []string for _, c := range commits { @@ -48,11 +46,7 @@ func assertHashes(c *C, commits []*Commit, hashes []string) { func validIfCommit(ignored plumbing.Hash) CommitFilter { return func(c *Commit) bool { - if c.Hash == ignored { - return true - } - - return false + return c.Hash == ignored } } |