mirror of
https://github.com/NousResearch/hermes-agent.git
synced 2026-07-21 16:18:55 +00:00
test(windows): capture bootstrap only in msys wrap-command tests
Same fix as the base-env bootstrap tests: init_session's post-failure non-login probe was overwriting captured["script"] with `true`. Capture the first (bootstrap) _run_bash call via setdefault.
This commit is contained in:
parent
c707165212
commit
f0d22e4b6c
1 changed files with 3 additions and 3 deletions
|
|
@ -353,7 +353,7 @@ class TestWrapCommandWindowsNativeCwd:
|
|||
captured = {}
|
||||
|
||||
def fake_run_bash(self, cmd_string, *, login=False, timeout=120, stdin_data=None):
|
||||
captured["script"] = cmd_string
|
||||
captured.setdefault("script", cmd_string) # bootstrap only; ignore the failure-path probe
|
||||
raise RuntimeError("stop after capturing bootstrap")
|
||||
|
||||
monkeypatch.setattr(LocalEnvironment, "_run_bash", fake_run_bash)
|
||||
|
|
@ -373,7 +373,7 @@ class TestWrapCommandWindowsNativeCwd:
|
|||
captured = {}
|
||||
|
||||
def fake_run_bash(self, cmd_string, *, login=False, timeout=120, stdin_data=None):
|
||||
captured["script"] = cmd_string
|
||||
captured.setdefault("script", cmd_string) # bootstrap only; ignore the failure-path probe
|
||||
raise RuntimeError("stop after capturing bootstrap")
|
||||
|
||||
monkeypatch.setattr(LocalEnvironment, "_run_bash", fake_run_bash)
|
||||
|
|
@ -402,7 +402,7 @@ class TestWrapCommandWindowsNativeCwd:
|
|||
captured = {}
|
||||
|
||||
def fake_run_bash(self, cmd_string, *, login=False, timeout=120, stdin_data=None):
|
||||
captured["script"] = cmd_string
|
||||
captured.setdefault("script", cmd_string) # bootstrap only; ignore the failure-path probe
|
||||
raise RuntimeError("stop after capturing bootstrap")
|
||||
|
||||
monkeypatch.setattr(LocalEnvironment, "_run_bash", fake_run_bash)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue