summaryrefslogtreecommitdiffstats
path: root/pkg/gui/controllers/helpers/upstream_helper_test.go
diff options
context:
space:
mode:
authorJesse Duffield <jessedduffield@gmail.com>2023-07-24 13:06:42 +1000
committerJesse Duffield <jessedduffield@gmail.com>2023-07-30 18:51:23 +1000
commite33fe37a99d4b3866970b1b2f40169d1bc9afa2e (patch)
tree0027f612fb72b2603044d04389da0236df28d864 /pkg/gui/controllers/helpers/upstream_helper_test.go
parentea54cb6e9c07ebca4a53e691fcb3cf993c793a50 (diff)
Standardise on using lo for slice functions
We've been sometimes using lo and sometimes using my slices package, and we need to pick one for consistency. Lo is more extensive and better maintained so we're going with that. My slices package was a superset of go's own slices package so in some places I've just used the official one (the methods were just wrappers anyway). I've also moved the remaining methods into the utils package.
Diffstat (limited to 'pkg/gui/controllers/helpers/upstream_helper_test.go')
-rw-r--r--pkg/gui/controllers/helpers/upstream_helper_test.go4
1 files changed, 2 insertions, 2 deletions
diff --git a/pkg/gui/controllers/helpers/upstream_helper_test.go b/pkg/gui/controllers/helpers/upstream_helper_test.go
index ac7a6a8bf..9742ef944 100644
--- a/pkg/gui/controllers/helpers/upstream_helper_test.go
+++ b/pkg/gui/controllers/helpers/upstream_helper_test.go
@@ -3,8 +3,8 @@ package helpers
import (
"testing"
- "github.com/jesseduffield/generics/slices"
"github.com/jesseduffield/lazygit/pkg/commands/models"
+ "github.com/samber/lo"
"github.com/stretchr/testify/assert"
)
@@ -25,7 +25,7 @@ func TestGetSuggestedRemote(t *testing.T) {
}
func mkRemoteList(names ...string) []*models.Remote {
- return slices.Map(names, func(name string) *models.Remote {
+ return lo.Map(names, func(name string, _ int) *models.Remote {
return &models.Remote{Name: name}
})
}