()
| 21 | |
| 22 | @pytest.mark.asyncio |
| 23 | async def test_css_selector(): |
| 24 | async with AsyncWebCrawler(verbose=True) as crawler: |
| 25 | url = "https://www.nbcnews.com/business" |
| 26 | css_selector = "h1, h2, h3" |
| 27 | result = await crawler.arun(url=url, css_selector=css_selector, bypass_cache=True) |
| 28 | |
| 29 | assert result.success |
| 30 | assert "<h1" in result.cleaned_html or "<h2" in result.cleaned_html or "<h3" in result.cleaned_html |
| 31 | |
| 32 | @pytest.mark.asyncio |
| 33 | async def test_javascript_execution(): |
nothing calls this directly
no test coverage detected
searching dependent graphs…