Skip to content

Commit

Permalink
milvus: Add test for empty documents
Browse files Browse the repository at this point in the history
  • Loading branch information
AloizioMacedo committed Aug 23, 2024
1 parent 4a54055 commit 830fa02
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions vectorstores/milvus/milvus_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -117,3 +117,14 @@ func TestMilvusConnection(t *testing.T) {
require.NoError(t, err)
require.Len(t, japanRes, 1)
}

func TestEmptyDocuments(t *testing.T) {
t.Parallel()
storer, err := getNewStore(t, WithDropOld(), WithCollectionName("test"))
require.NoError(t, err)

data := []schema.Document{}

_, err = storer.AddDocuments(context.Background(), data)
require.NoError(t, err)
}

0 comments on commit 830fa02

Please sign in to comment.