a2a-source-edit: remove smoke_tests/test_iterative_quotes_plan.py
This commit is contained in:
@@ -1,46 +0,0 @@
|
|||||||
from __future__ import annotations
|
|
||||||
|
|
||||||
import inspect
|
|
||||||
from pathlib import Path
|
|
||||||
|
|
||||||
|
|
||||||
def _load_agent_class():
|
|
||||||
import importlib.util
|
|
||||||
|
|
||||||
agent_path = Path(__file__).resolve().parents[1] / "agent.py"
|
|
||||||
spec = importlib.util.spec_from_file_location("agent", agent_path)
|
|
||||||
assert spec is not None and spec.loader is not None
|
|
||||||
module = importlib.util.module_from_spec(spec)
|
|
||||||
spec.loader.exec_module(module)
|
|
||||||
return getattr(module, "SeleniumbaseWebsiteScraper")
|
|
||||||
|
|
||||||
|
|
||||||
def test_iterative_signature_has_required_params() -> None:
|
|
||||||
Agent = _load_agent_class()
|
|
||||||
fn = getattr(Agent, "iterative_scrape_goal")
|
|
||||||
sig = inspect.signature(fn)
|
|
||||||
params = set(sig.parameters.keys())
|
|
||||||
# skill method signature includes (self, ctx, ...)
|
|
||||||
required = {
|
|
||||||
"ctx",
|
|
||||||
"goal",
|
|
||||||
"start_url",
|
|
||||||
"allowed_domains",
|
|
||||||
"seed_selectors",
|
|
||||||
"max_steps",
|
|
||||||
"max_pages",
|
|
||||||
"max_runtime_seconds",
|
|
||||||
"wait_seconds",
|
|
||||||
"output_format",
|
|
||||||
"headless",
|
|
||||||
"user_agent",
|
|
||||||
"respect_robots",
|
|
||||||
"rate_limit_seconds",
|
|
||||||
"screenshot",
|
|
||||||
}
|
|
||||||
assert required.issubset(params)
|
|
||||||
|
|
||||||
|
|
||||||
if __name__ == "__main__":
|
|
||||||
test_iterative_signature_has_required_params()
|
|
||||||
print("iterative signature smoke ok")
|
|
||||||
Reference in New Issue
Block a user