From fc43514b2ac9bfb15d7a85aaeb2fbfd5c77f7166 Mon Sep 17 00:00:00 2001 From: Seongho Bae Date: Fri, 7 Aug 2026 20:29:01 +0900 Subject: [PATCH] test(opencode): require trusted asyncio test runtime --- ...test_opencode_asyncio_toolchain_contract.py | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) create mode 100644 tests/test_opencode_asyncio_toolchain_contract.py diff --git a/tests/test_opencode_asyncio_toolchain_contract.py b/tests/test_opencode_asyncio_toolchain_contract.py new file mode 100644 index 000000000..4b35ee94f --- /dev/null +++ b/tests/test_opencode_asyncio_toolchain_contract.py @@ -0,0 +1,18 @@ +from pathlib import Path + + +REVIEW_REQUIREMENTS_PATH = Path("requirements-opencode-review-ci.txt") +REVIEW_HASH_LOCK_PATH = Path("requirements-opencode-review-ci-hashes.txt") +REVIEW_WORKFLOW_PATH = Path(".github/workflows/opencode-review-dispatch.yml") + + +def test_opencode_coverage_toolchain_supports_repository_asyncio_tests() -> None: + """Keep the trusted coverage sandbox able to execute marked asyncio tests.""" + + requirements = REVIEW_REQUIREMENTS_PATH.read_text(encoding="utf-8") + hash_lock = REVIEW_HASH_LOCK_PATH.read_text(encoding="utf-8") + workflow = REVIEW_WORKFLOW_PATH.read_text(encoding="utf-8") + + assert "pytest-asyncio==1.4.0" in requirements + assert "pytest-asyncio==1.4.0" in hash_lock + assert "import coverage, interrogate, pytest, pytest_asyncio, pytest_cov" in workflow