Skip to content

Commit

Permalink
Fix asserting the embedders after meilisearch v1.6
Browse files Browse the repository at this point in the history
  • Loading branch information
brunoocasali committed Jan 15, 2024
1 parent 01e7e32 commit 5440a6a
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 4 deletions.
2 changes: 1 addition & 1 deletion src/Endpoints/Delegates/HandlesSettings.php
Original file line number Diff line number Diff line change
Expand Up @@ -364,7 +364,7 @@ public function resetProximityPrecision(): array

// Settings - Experimental: Embedders (hybrid search)

public function getEmbedders(): array
public function getEmbedders(): ?array
{
return $this->http->get(self::PATH.'/'.$this->uid.'/settings/embedders');
}
Expand Down
5 changes: 2 additions & 3 deletions tests/Settings/EmbeddersTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ public function testGetEmbedders(): void
$index = $this->createEmptyIndex($this->safeIndexName('books-1'));
$embedders = $index->getEmbedders();

$this->assertEquals([], $embedders);
$this->assertEmpty($embedders);
}

public function testUpdateEmbeddersWithOpenAi(): void
Expand Down Expand Up @@ -98,7 +98,6 @@ public function testResetEmbedders(): void
$this->assertIsValidPromise($promise);
$index->waitForTask($promise['taskUid']);

$embedders = $index->getEmbedders();
$this->assertEquals([], $embedders);
$this->assertEmpty($index->getEmbedders());
}
}

0 comments on commit 5440a6a

Please sign in to comment.