1948062188
Updated tests to inspect _render_ai_settings_hub instead of _gui_func as the RAG settings panel was moved during GUI refactoring.
15 lines
538 B
Python
15 lines
538 B
Python
|
|
import pytest
|
|
from src.gui_2 import App
|
|
|
|
def test_rag_panel_exists():
|
|
"""Verify that _render_rag_panel has been added to the App class."""
|
|
assert hasattr(App, '_render_rag_panel')
|
|
assert callable(App._render_rag_panel)
|
|
|
|
def test_rag_panel_integration():
|
|
"""Verify that _render_ai_settings_hub calls _render_rag_panel by inspecting source or via mock."""
|
|
import inspect
|
|
source = inspect.getsource(App._render_ai_settings_hub)
|
|
assert "self._render_rag_panel()" in source
|
|
assert "imgui.collapsing_header(\"RAG Settings\")" in source |