Skip to content

Commit

Permalink
Add unit test for graph rag interfaces
Browse files Browse the repository at this point in the history
  • Loading branch information
randombet committed Sep 4, 2024
1 parent 94ea2b5 commit a9c53aa
Showing 1 changed file with 17 additions and 0 deletions.
17 changes: 17 additions & 0 deletions test/agentchat/contrib/graph_rag/test_graph_rag_basic.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
from unittest.mock import Mock

from autogen.agentchat.contrib.graph_rag.graph_query_engine import GraphQueryEngine
from autogen.agentchat.contrib.graph_rag.graph_rag_capability import GraphRagCapability
from autogen.agentchat.conversable_agent import ConversableAgent


def test_dry_run():
"""Dry run for basic graph rag objects."""
mock_graph_query_engine = Mock(spec=GraphQueryEngine)

graph_rag_agent = ConversableAgent(
name="graph_rag_agent",
max_consecutive_auto_reply=3,
)
graph_rag_capability = GraphRagCapability(mock_graph_query_engine)
graph_rag_capability.add_to_agent(graph_rag_agent)

0 comments on commit a9c53aa

Please sign in to comment.