refactor tavily_crawler test
This commit is contained in:
parent
3f5c09eb45
commit
a35bcecdf9
1 changed files with 1 additions and 4 deletions
|
|
@ -1,14 +1,11 @@
|
|||
import os
|
||||
import pytest
|
||||
from cognee.tasks.web_scraper.config import TavilyConfig
|
||||
from cognee.tasks.web_scraper.utils import fetch_with_tavily
|
||||
|
||||
|
||||
@pytest.mark.asyncio
|
||||
async def test_fetch():
|
||||
url = "https://en.wikipedia.org/wiki/Large_language_model"
|
||||
tavily_config = TavilyConfig()
|
||||
results = await fetch_with_tavily(url, tavily_config)
|
||||
results = await fetch_with_tavily(url)
|
||||
assert len(results) == 1
|
||||
assert isinstance(results, dict)
|
||||
html = results[url]
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue