Skip to content

The agent that grows with you

test: pin cua-driver resolver in CLI-fallback sanitization test

Teknium28cc6599dff8
diff --git a/tests/computer_use/test_cua_spawn_env_sanitization.py b/tests/computer_use/test_cua_spawn_env_sanitization.py
index 8692365e574..dbf7353f1c5 100644
--- a/tests/computer_use/test_cua_spawn_env_sanitization.py
+++ b/tests/computer_use/test_cua_spawn_env_sanitization.py
@@ -111,6 +111,11 @@ def test_cli_fallback_sanitizes_env_and_hides_console_on_windows(monkeypatch):
captured = {}
_patch_windows_hide_flags(monkeypatch, cua_backend)
+ # Hermetic CI has no cua-driver binary; pin the resolver so the test
+ # exercises the spawn-env path instead of the install-hint early exit.
+ monkeypatch.setattr(
+ cua_backend, "resolve_cua_driver_cmd", lambda override=None: "cua-driver"
+ )
monkeypatch.setattr(
cua_backend.subprocess,
"run",