diff --git a/tests_v2/test_browser_skill_get_selector_docs.py b/tests_v2/test_browser_skill_get_selector_docs.py deleted file mode 100644 index 92c5a8f9..00000000 --- a/tests_v2/test_browser_skill_get_selector_docs.py +++ /dev/null @@ -1,34 +0,0 @@ -#!/usr/bin/env python3 -"""Regression checks for cmux-browser get selector examples.""" - -import sys -from pathlib import Path - -sys.path.insert(0, str(Path(__file__).parent)) -from cmux import cmuxError - - -ROOT = Path(__file__).resolve().parents[1] -COMMANDS = ROOT / "skills/cmux-browser/references/commands.md" - - -def _must(cond: bool, msg: str) -> None: - if not cond: - raise cmuxError(msg) - - -def main() -> int: - commands = COMMANDS.read_text(encoding="utf-8") - - _must("`agent-browser get text ` -> `cmux browser get text `" in commands, "Expected get text mapping to mention selector support") - _must("cmux browser get text body" in commands, "Expected get text body example") - _must("cmux browser get html body" in commands, "Expected get html body example") - _must('cmux browser get value "#email"' in commands, "Expected get value selector example") - _must('cmux browser get attr "#email" --attr placeholder' in commands, "Expected get attr selector example") - _must("cmux browser get text|html|value|attr|count|box|styles ..." not in commands, "Unexpected bare get example block") - - return 0 - - -if __name__ == "__main__": - raise SystemExit(main()) diff --git a/tests_v2/test_browser_skill_js_error_docs.py b/tests_v2/test_browser_skill_js_error_docs.py deleted file mode 100644 index 566ab10f..00000000 --- a/tests_v2/test_browser_skill_js_error_docs.py +++ /dev/null @@ -1,35 +0,0 @@ -#!/usr/bin/env python3 -"""Regression checks for cmux-browser js_error troubleshooting docs.""" - -import sys -from pathlib import Path - -sys.path.insert(0, str(Path(__file__).parent)) -from cmux import cmuxError - - -ROOT = Path(__file__).resolve().parents[1] -SKILL = ROOT / "skills/cmux-browser/SKILL.md" - - -def _must(cond: bool, msg: str) -> None: - if not cond: - raise cmuxError(msg) - - -def main() -> int: - skill = SKILL.read_text(encoding="utf-8") - - _must("## Troubleshooting" in skill, "Expected Troubleshooting section in cmux-browser skill") - _must("### `js_error` on `snapshot --interactive` or `eval`" in skill, "Expected js_error troubleshooting heading") - _must("cmux browser surface:7 get url" in skill, "Expected get url recovery step") - _must("cmux browser surface:7 get text body" in skill, "Expected get text body recovery step") - _must("cmux browser surface:7 get html body" in skill, "Expected get html body recovery step") - _must("when `snapshot --interactive` or `eval` returns `js_error`" in skill, "Expected js_error fallback guidance") - _must("navigate to a simpler intermediate page" in skill, "Expected simpler-page fallback guidance") - - return 0 - - -if __name__ == "__main__": - raise SystemExit(main())