mirror of
https://github.com/meta-llama/llama-stack.git
synced 2025-12-15 17:02:41 +00:00
close connections
This commit is contained in:
parent
22077e7f32
commit
fa100c77fd
7 changed files with 13 additions and 5 deletions
|
|
@ -18,6 +18,7 @@ async def sqlite_kvstore(tmp_path):
|
|||
kvstore = SqliteKVStoreImpl(kvstore_config)
|
||||
await kvstore.initialize()
|
||||
yield kvstore
|
||||
await kvstore.close()
|
||||
|
||||
|
||||
@pytest.fixture(scope="function")
|
||||
|
|
|
|||
|
|
@ -46,12 +46,9 @@ async def test_initialize_index(vector_index):
|
|||
|
||||
|
||||
async def test_add_chunks_query_vector(vector_index, sample_chunks, sample_embeddings):
|
||||
vector_index.delete()
|
||||
vector_index.initialize()
|
||||
await vector_index.add_chunks(sample_chunks, sample_embeddings)
|
||||
resp = await vector_index.query_vector(sample_embeddings[0], k=1, score_threshold=-1)
|
||||
assert resp.chunks[0].content == sample_chunks[0].content
|
||||
vector_index.delete()
|
||||
|
||||
|
||||
async def test_chunk_id_conflict(vector_index, sample_chunks, embedding_dimension):
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue