Co-authored-by: -LAN- <laipz8200@outlook.com>
This commit is contained in:
@@ -12,13 +12,13 @@ class PGVectoRSVectorTest(AbstractVectorTest):
|
||||
self.vector = PGVectoRS(
|
||||
collection_name=self.collection_name.lower(),
|
||||
config=PgvectoRSConfig(
|
||||
host='localhost',
|
||||
host="localhost",
|
||||
port=5431,
|
||||
user='postgres',
|
||||
password='difyai123456',
|
||||
database='dify',
|
||||
user="postgres",
|
||||
password="difyai123456",
|
||||
database="dify",
|
||||
),
|
||||
dim=128
|
||||
dim=128,
|
||||
)
|
||||
|
||||
def search_by_full_text(self):
|
||||
@@ -27,8 +27,9 @@ class PGVectoRSVectorTest(AbstractVectorTest):
|
||||
assert len(hits_by_full_text) == 0
|
||||
|
||||
def get_ids_by_metadata_field(self):
|
||||
ids = self.vector.get_ids_by_metadata_field(key='document_id', value=self.example_doc_id)
|
||||
ids = self.vector.get_ids_by_metadata_field(key="document_id", value=self.example_doc_id)
|
||||
assert len(ids) == 1
|
||||
|
||||
|
||||
def test_pgvecot_rs(setup_mock_redis):
|
||||
PGVectoRSVectorTest().run_all_tests()
|
||||
|
||||
Reference in New Issue
Block a user