Skip to content

Commit 503303e

Browse files
meili-bors[bot]meili-botcurquiza
authored
Merge #503
503: Update tests related to the next Meilisearch release (v1.6.0) r=curquiza a=meili-bot Related to this issue: meilisearch/integration-guides#294 This PR: - gathers the changes related to the next Meilisearch release (v1.6.0) so that this package is ready when the official release is out. - should pass the tests against the [latest pre-release of Meilisearch](https://github.com/meilisearch/meilisearch/releases). - might eventually contain test failures until the Meilisearch v1.6.0 is out. ⚠️ This PR should NOT be merged until the next release of Meilisearch (v1.6.0) is out. _This PR is auto-generated for the [pre-release week](https://github.com/meilisearch/integration-guides/blob/main/resources/pre-release-week.md) purpose._ Co-authored-by: meili-bot <[email protected]> Co-authored-by: curquiza <[email protected]> Co-authored-by: Clémentine U. - curqui <[email protected]>
2 parents 0b52e5e + e231ddb commit 503303e

File tree

2 files changed

+33
-30
lines changed

2 files changed

+33
-30
lines changed

README.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -238,6 +238,8 @@ searchRes, err := index.Search("wonder",
238238

239239
This package guarantees compatibility with [version v1.x of Meilisearch](https://github.com/meilisearch/meilisearch/releases/latest), but some features may not be present. Please check the [issues](https://github.com/meilisearch/meilisearch-go/issues?q=is%3Aissue+is%3Aopen+label%3A%22good+first+issue%22+label%3Aenhancement) for more info.
240240

241+
⚠️ This package is not compatible with the [`vectoreStore` experimental feature](https://www.meilisearch.com/docs/learn/experimental/vector_search) of Meilisearch v1.6.0 and later. More information on this [issue](https://github.com/meilisearch/meilisearch-go/issues/504).
242+
241243
## 💡 Learn more
242244

243245
The following sections in our main documentation website may interest you:

index_search_test.go

Lines changed: 31 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -1600,38 +1600,39 @@ func TestIndex_SearchWithShowRankingScore(t *testing.T) {
16001600
require.NotNil(t, got.Hits[0].(map[string]interface{})["_rankingScore"])
16011601
}
16021602

1603-
func TestIndex_SearchWithVectorStore(t *testing.T) {
1604-
type args struct {
1605-
UID string
1606-
PrimaryKey string
1607-
client *Client
1608-
query string
1609-
request SearchRequest
1610-
}
1611-
testArg := args{
1612-
UID: "indexUID",
1613-
client: defaultClient,
1614-
query: "Pride and Prejudice",
1615-
request: SearchRequest{
1616-
Vector: []float64{0.1, 0.2, 0.3},
1617-
},
1618-
}
1603+
// Commented because of https://github.com/meilisearch/meilisearch-go/issues/504
1604+
// func TestIndex_SearchWithVectorStore(t *testing.T) {
1605+
// type args struct {
1606+
// UID string
1607+
// PrimaryKey string
1608+
// client *Client
1609+
// query string
1610+
// request SearchRequest
1611+
// }
1612+
// testArg := args{
1613+
// UID: "indexUID",
1614+
// client: defaultClient,
1615+
// query: "Pride and Prejudice",
1616+
// request: SearchRequest{
1617+
// Vector: []float64{0.1, 0.2, 0.3},
1618+
// },
1619+
// }
16191620

1620-
i, err := SetUpIndexWithVector(testArg.UID)
1621-
if err != nil {
1622-
t.Fatal(err)
1623-
}
1621+
// i, err := SetUpIndexWithVector(testArg.UID)
1622+
// if err != nil {
1623+
// t.Fatal(err)
1624+
// }
16241625

1625-
c := testArg.client
1626-
t.Cleanup(cleanup(c))
1626+
// c := testArg.client
1627+
// t.Cleanup(cleanup(c))
16271628

1628-
got, err := i.Search(testArg.query, &testArg.request)
1629-
require.NoError(t, err)
1630-
require.NotNil(t, got.Hits[0].(map[string]interface{})["_vectors"])
1629+
// got, err := i.Search(testArg.query, &testArg.request)
1630+
// require.NoError(t, err)
1631+
// require.NotNil(t, got.Hits[0].(map[string]interface{})["_vectors"])
16311632

1632-
vectorsRes := got.Hits[0].(map[string]interface{})["_vectors"].([]interface{})
1633+
// vectorsRes := got.Hits[0].(map[string]interface{})["_vectors"].([]interface{})
16331634

1634-
for i := range vectorsRes {
1635-
require.Equal(t, testArg.request.Vector[i], vectorsRes[i])
1636-
}
1637-
}
1635+
// for i := range vectorsRes {
1636+
// require.Equal(t, testArg.request.Vector[i], vectorsRes[i])
1637+
// }
1638+
// }

0 commit comments

Comments
 (0)