mirror of
https://gitee.com/milvus-io/milvus.git
synced 2024-12-01 03:18:29 +08:00
a5e2d6b6fb
Signed-off-by: longjiquan <jiquan.long@zilliz.com> Co-authored-by: xaxys <tpnnghd@163.com> Signed-off-by: longjiquan <jiquan.long@zilliz.com> Co-authored-by: xaxys <tpnnghd@163.com>
36 lines
495 B
Go
36 lines
495 B
Go
package metastore
|
|
|
|
import "testing"
|
|
|
|
func TestAlterType_String(t *testing.T) {
|
|
tests := []struct {
|
|
name string
|
|
t AlterType
|
|
want string
|
|
}{
|
|
{
|
|
t: ADD,
|
|
want: "ADD",
|
|
},
|
|
{
|
|
t: DELETE,
|
|
want: "DELETE",
|
|
},
|
|
{
|
|
t: MODIFY,
|
|
want: "MODIFY",
|
|
},
|
|
{
|
|
t: -1,
|
|
want: "",
|
|
},
|
|
}
|
|
for _, tt := range tests {
|
|
t.Run(tt.name, func(t *testing.T) {
|
|
if got := tt.t.String(); got != tt.want {
|
|
t.Errorf("String() = %v, want %v", got, tt.want)
|
|
}
|
|
})
|
|
}
|
|
}
|