1
0
mirror of https://github.com/jesseduffield/lazygit.git synced 2024-12-14 11:23:09 +02:00
lazygit/pkg/gui/presentation/commits_test.go

18 lines
372 B
Go
Raw Normal View History

2021-10-23 09:17:35 +02:00
package presentation
import "testing"
func TestGetInitials(t *testing.T) {
for input, output := range map[string]string{
"Jesse Duffield": "JD",
"Jesse Duffield Man": "JD",
"JesseDuffield": "Je",
"J": "J",
"": "",
} {
if output != getInitials(input) {
t.Errorf("Expected %s to be %s", input, output)
}
}
}