Skip to content

Adapt tests for stabilization vector store usage #607

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Feb 8, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion spec/meilisearch/index/documents_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,6 @@
end

it 'allows the user to store vectors' do
enable_vector_store(true)
new_doc = { objectId: 123, _vectors: { default: [0.1, 0.2, 0.3] } }
client.create_index('vector_test').await
new_index = client.index('vector_test')
Expand Down
2 changes: 0 additions & 2 deletions spec/meilisearch/index/search/similar_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,6 @@
end

it 'does a search for similar documents' do
enable_vector_store(true)

documents = [
{
title: 'Shazam!',
Expand Down
2 changes: 0 additions & 2 deletions spec/meilisearch/index/search/vector_search_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,6 @@

RSpec.describe 'Meilisearch::Index - Vector search' do
it 'does a basic search' do
enable_vector_store(true)

documents = [
{ objectId: 0, _vectors: { custom: [0, 0.8, -0.2] }, title: 'Across The Universe' },
{ objectId: 1, _vectors: { custom: [1, -0.2, 0] }, title: 'All Things Must Pass' },
Expand Down
3 changes: 1 addition & 2 deletions spec/meilisearch/index/settings_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -850,10 +850,9 @@

context 'on embedders' do
let(:index) { client.index(uid) }
let(:default_embedders) { nil }
let(:default_embedders) { {} }

before { client.create_index(uid).await }
before { enable_vector_store(true) }

it '#embedders gets default value' do
expect(index.embedders).to eq(default_embedders)
Expand Down
4 changes: 0 additions & 4 deletions spec/support/experimental_feature_helpers.rb
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,6 @@
require 'json'

module ExperimentalFeatureHelpers
def enable_vector_store(toggle)
configure_feature('vectorStore', toggle)
end

def enable_edit_documents_by_function(toggle)
configure_feature('editDocumentsByFunction', toggle)
end
Expand Down