mirror of
https://gitee.com/milvus-io/milvus.git
synced 2026-01-05 02:12:48 +08:00
24 lines
390 B
Go
24 lines
390 B
Go
package mock
|
|
|
|
import (
|
|
"fmt"
|
|
"testing"
|
|
"time"
|
|
)
|
|
|
|
var C = Collection{
|
|
ID: uint64(11111),
|
|
Name: "test-collection",
|
|
CreateTime: uint64(time.Now().Unix()),
|
|
SegmentIDs: []uint64{uint64(10111)},
|
|
PartitionTags: []string{"default"},
|
|
}
|
|
|
|
func TestCollection2JSON(t *testing.T) {
|
|
res, err := Collection2JSON(C)
|
|
if err != nil {
|
|
t.Error(err)
|
|
}
|
|
fmt.Println(res)
|
|
}
|