mirror of
https://github.com/langgenius/dify.git
synced 2026-05-04 01:18:05 +08:00
refactor: decouple database operations from knowledge retrieval nodes (#31981)
Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
This commit is contained in:
@ -0,0 +1,29 @@
|
||||
"""
|
||||
Integration tests for KnowledgeRetrievalNode.
|
||||
|
||||
This module provides integration tests for KnowledgeRetrievalNode with real database interactions.
|
||||
|
||||
Note: These tests require database setup and are more complex than unit tests.
|
||||
For now, we focus on unit tests which provide better coverage for the node logic.
|
||||
"""
|
||||
|
||||
import pytest
|
||||
|
||||
|
||||
class TestKnowledgeRetrievalNodeIntegration:
|
||||
"""
|
||||
Integration test suite for KnowledgeRetrievalNode.
|
||||
|
||||
Note: Full integration tests require:
|
||||
- Database setup with datasets and documents
|
||||
- Vector store for embeddings
|
||||
- Model providers for retrieval
|
||||
|
||||
For now, unit tests provide comprehensive coverage of the node logic.
|
||||
"""
|
||||
|
||||
@pytest.mark.skip(reason="Integration tests require full database and vector store setup")
|
||||
def test_end_to_end_knowledge_retrieval(self):
|
||||
"""Test end-to-end knowledge retrieval workflow."""
|
||||
# TODO: Implement with real database
|
||||
pass
|
||||
Reference in New Issue
Block a user