15 lines
361 B
Go
15 lines
361 B
Go
package main
|
|
|
|
import "testing"
|
|
|
|
func TestCompletionKind(t *testing.T) {
|
|
for _, tc := range []struct {
|
|
in int
|
|
want string
|
|
}{{1, "Text"}, {2, "Method"}, {3, "Function"}, {25, "TypeParameter"}, {0, "Unknown"}, {99, "Unknown"}} {
|
|
if got := completionKind(tc.in); got != tc.want {
|
|
t.Errorf("completionKind(%d)=%q want %q", tc.in, got, tc.want)
|
|
}
|
|
}
|
|
}
|