Skip to content

Commit

Permalink
fix(test): Fix test that was being skipped because of missing async m…
Browse files Browse the repository at this point in the history
…arker

- Fix a test case in test_web_selenium.py that was failing due to a missing `pytest.mark.asyncio`
  • Loading branch information
Pwuts committed Dec 5, 2023
1 parent b73fa47 commit 47dc5ad
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion autogpts/autogpt/tests/integration/test_web_selenium.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,13 +6,14 @@

@pytest.mark.vcr
@pytest.mark.requires_openai_api_key
@pytest.mark.asyncio
async def test_browse_website_nonexistent_url(
agent: Agent, patched_api_requestor: None
):
url = "https://auto-gpt-thinks-this-website-does-not-exist.com"
question = "How to execute a barrel roll"

with pytest.raises(BrowsingError, match=r"NAME_NOT_RESOLVED") as raised:
with pytest.raises(BrowsingError, match="NAME_NOT_RESOLVED") as raised:
await read_webpage(url=url, question=question, agent=agent)

# Sanity check that the response is not too long
Expand Down

0 comments on commit 47dc5ad

Please sign in to comment.