mirror of
https://github.com/MODSetter/SurfSense.git
synced 2026-04-25 08:46:22 +02:00
fix: update LlamaCloud test assertions to reflect new parse modes
- Changed assertions in `test_llamacloud_basic_uses_cost_effective_tier` to check for `parse_page_with_llm` instead of `cost_effective` tier. - Updated `test_llamacloud_premium_uses_agentic_plus_tier` to verify `parse_page_with_agent` instead of `agentic_plus` tier. - Ensured that `tier` is no longer included in the call arguments.
This commit is contained in:
parent
e7fba022c1
commit
635bf8ba96
1 changed files with 6 additions and 4 deletions
|
|
@ -862,7 +862,7 @@ async def test_azure_di_premium_uses_prebuilt_layout(tmp_path, mocker):
|
|||
|
||||
|
||||
async def test_llamacloud_basic_uses_cost_effective_tier(tmp_path, mocker):
|
||||
"""Basic mode should use cost_effective tier for LlamaCloud."""
|
||||
"""Basic mode should use parse_page_with_llm parse_mode for LlamaCloud."""
|
||||
pdf_file = tmp_path / "report.pdf"
|
||||
pdf_file.write_bytes(b"%PDF-1.4 fake content " * 10)
|
||||
|
||||
|
|
@ -890,11 +890,12 @@ async def test_llamacloud_basic_uses_cost_effective_tier(tmp_path, mocker):
|
|||
|
||||
assert result.markdown_content == "# Llama basic"
|
||||
call_kwargs = llama_parse_cls.call_args[1]
|
||||
assert call_kwargs["tier"] == "cost_effective"
|
||||
assert call_kwargs["parse_mode"] == "parse_page_with_llm"
|
||||
assert "tier" not in call_kwargs
|
||||
|
||||
|
||||
async def test_llamacloud_premium_uses_agentic_plus_tier(tmp_path, mocker):
|
||||
"""Premium mode should use agentic_plus tier for LlamaCloud."""
|
||||
"""Premium mode should use parse_page_with_agent parse_mode for LlamaCloud."""
|
||||
pdf_file = tmp_path / "report.pdf"
|
||||
pdf_file.write_bytes(b"%PDF-1.4 fake content " * 10)
|
||||
|
||||
|
|
@ -922,4 +923,5 @@ async def test_llamacloud_premium_uses_agentic_plus_tier(tmp_path, mocker):
|
|||
|
||||
assert result.markdown_content == "# Llama premium"
|
||||
call_kwargs = llama_parse_cls.call_args[1]
|
||||
assert call_kwargs["tier"] == "agentic_plus"
|
||||
assert call_kwargs["parse_mode"] == "parse_page_with_agent"
|
||||
assert "tier" not in call_kwargs
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue