Skip to content

Commit f5190e0

Browse files
meili-bors[bot]meili-botStrift
authored
Merge #716
716: Changes related to the next Meilisearch release (v1.13) r=brunoocasali a=meili-bot Related to this issue: meilisearch/integration-guides#314 This PR: - gathers the changes related to the next Meilisearch release (v1.13) 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.13 is out. ⚠️ This PR should NOT be merged until the next release of Meilisearch (v1.13) 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: Laurent Cazanove <[email protected]>
2 parents ec43c8a + ba5ca4b commit f5190e0

File tree

5 files changed

+10
-28
lines changed

5 files changed

+10
-28
lines changed

.code-samples.meilisearch.yaml

+9
Original file line numberDiff line numberDiff line change
@@ -791,3 +791,12 @@ get_all_batches_1: |-
791791
$client->getBatches();
792792
get_batch_1: |-
793793
$client->getBatch(BATCH_UID);
794+
update_embedders_1: |-
795+
$client->updateEmbedders([
796+
'default' => [
797+
'source' => 'openAi',
798+
'apiKey' => 'OPEN_AI_API_KEY',
799+
'model' => 'text-embedding-3-small',
800+
'documentTemplate' => 'A document titled '{{doc.title}}' whose description starts with {{doc.overview|truncatewords: 20}}'
801+
]
802+
]);

tests/Endpoints/DocumentsTest.php

-2
Original file line numberDiff line numberDiff line change
@@ -680,8 +680,6 @@ public function testGetDocumentsWithoutFilterCorrectFieldsFormat(): void
680680

681681
public function testGetDocumentsWithVector(): void
682682
{
683-
$http = new Client($this->host, getenv('MEILISEARCH_API_KEY'));
684-
$http->patch('/experimental-features', ['vectorStore' => true]);
685683
$index = $this->createEmptyIndex($this->safeIndexName('movies'));
686684

687685
$promise = $index->updateEmbedders(['manual' => ['source' => 'userProvided', 'dimensions' => 3]]);

tests/Endpoints/SearchTest.php

-2
Original file line numberDiff line numberDiff line change
@@ -707,8 +707,6 @@ public function testBasicSearchWithFacetsOptionAndMultipleFacets(): void
707707

708708
public function testVectorSearch(): void
709709
{
710-
$http = new Client($this->host, getenv('MEILISEARCH_API_KEY'));
711-
$http->patch('/experimental-features', ['vectorStore' => true]);
712710
$index = $this->createEmptyIndex($this->safeIndexName());
713711

714712
$promise = $index->updateEmbedders(['manual' => ['source' => 'userProvided', 'dimensions' => 3]]);

tests/Settings/EmbeddersTest.php

+1-4
Original file line numberDiff line numberDiff line change
@@ -5,20 +5,17 @@
55
namespace Tests\Settings;
66

77
use Meilisearch\Endpoints\Indexes;
8-
use Meilisearch\Http\Client;
98
use Tests\TestCase;
109

1110
final class EmbeddersTest extends TestCase
1211
{
1312
private Indexes $index;
1413

15-
private const DEFAULT_EMBEDDER = null;
14+
private const DEFAULT_EMBEDDER = [];
1615

1716
protected function setUp(): void
1817
{
1918
parent::setUp();
20-
$http = new Client($this->host, getenv('MEILISEARCH_API_KEY'));
21-
$http->patch('/experimental-features', ['vectorStore' => true]);
2219
$this->index = $this->createEmptyIndex($this->safeIndexName());
2320
}
2421

tests/Settings/SettingsTest.php

-20
Original file line numberDiff line numberDiff line change
@@ -196,24 +196,4 @@ public function testResetSettings(): void
196196
self::assertSame(self::DEFAULT_FACET_SEARCH, $settings['facetSearch']);
197197
self::assertSame(self::DEFAULT_PREFIX_SEARCH, $settings['prefixSearch']);
198198
}
199-
200-
// Here the test to prevent https://github.com/meilisearch/meilisearch-php/issues/204.
201-
// Rollback this comment after meilisearch v1.6.0 final release.
202-
// Related to: https://github.com/meilisearch/meilisearch/issues/4323
203-
//
204-
// public function testGetThenUpdateSettings(): void
205-
// {
206-
// $http = new \Meilisearch\Http\Client($this->host, getenv('MEILISEARCH_API_KEY'));
207-
// $http->patch('/experimental-features', ['vectorStore' => false]);
208-
// $index = $this->createEmptyIndex($this->safeIndexName());
209-
210-
// $resetPromise = $index->resetSettings();
211-
// $this->assertIsValidPromise($resetPromise);
212-
// $index->waitForTask($resetPromise['taskUid']);
213-
214-
// $settings = $index->getSettings();
215-
// $promise = $index->updateSettings($settings);
216-
// $this->assertIsValidPromise($promise);
217-
// $index->waitForTask($promise['taskUid']);
218-
// }
219199
}

0 commit comments

Comments
 (0)