feat: adds missing tests to context extension retriever integration test

This commit is contained in:
hajdul88 2025-12-10 11:46:37 +01:00
parent 723bcd70a2
commit 6a057711a2

View file

@ -213,3 +213,14 @@ async def test_get_graph_completion_extension_context_on_empty_graph(setup_test_
assert all(isinstance(item, str) and item.strip() for item in answer), (
"Answer must contain only non-empty strings"
)
@pytest.mark.asyncio
async def test_graph_completion_extension_get_triplets_empty(setup_test_environment_empty):
"""Integration test: verify GraphCompletionContextExtensionRetriever get_triplets handles empty graph."""
retriever = GraphCompletionContextExtensionRetriever()
triplets = await retriever.get_triplets("Who works at Figma?")
assert isinstance(triplets, list), "Triplets should be a list"
assert len(triplets) == 0, "Should return empty list on empty graph"