deploy
This commit is contained in:
21
tests/test_agent.py
Normal file
21
tests/test_agent.py
Normal file
@@ -0,0 +1,21 @@
|
||||
from __future__ import annotations
|
||||
|
||||
import pytest
|
||||
|
||||
from a2a_pack import LocalRunContext, NoAuth
|
||||
|
||||
from agent import SelfHealingDemo
|
||||
|
||||
|
||||
@pytest.mark.asyncio
|
||||
async def test_controlled_failure_has_a_safe_result() -> None:
|
||||
agent = SelfHealingDemo()
|
||||
ctx = LocalRunContext(auth=NoAuth())
|
||||
|
||||
result = await agent.run(ctx, scenario="controlled-failure")
|
||||
|
||||
assert result == {
|
||||
"ok": True,
|
||||
"scenario": "controlled-failure",
|
||||
"result": "recovered",
|
||||
}
|
||||
Reference in New Issue
Block a user