1
0
mirror of https://github.com/jesseduffield/lazygit.git synced 2025-02-03 13:21:56 +02:00

test: fix TagNamesAt

Co-authored-by: Jesse Duffield <jessedduffield@gmail.com>
This commit is contained in:
Ryoga 2023-02-09 21:02:43 +09:00 committed by Ryooooooga
parent 36c2b00336
commit 72a92d748f
No known key found for this signature in database
GPG Key ID: 07CF200DFCC20C25

View File

@ -15,7 +15,7 @@ func (self *Git) CurrentBranchName(expectedName string) *Git {
}
func (self *Git) TagNamesAt(ref string, expectedNames []string) *Git {
return self.assert(fmt.Sprintf(`git tag --contains "%s"`, ref), strings.Join(expectedNames, "\n"))
return self.assert(fmt.Sprintf(`git tag --sort=v:refname --points-at "%s"`, ref), strings.Join(expectedNames, "\n"))
}
func (self *Git) assert(cmdStr string, expected string) *Git {