mirror of
https://github.com/HKUDS/nanobot.git
synced 2026-08-31 00:03:01 +03:00
test(ci): isolate Windows process checks
This commit is contained in:
@@ -96,10 +96,11 @@ jobs:
|
||||
os: windows-latest
|
||||
python-version: "3.14"
|
||||
coverage: false
|
||||
# Keep each test file in one worker while using both hosted-runner cores.
|
||||
# Keep test names visible until a Windows-only control-event
|
||||
# interruption can be attributed to its active worker/file.
|
||||
pytest_args: "-n 2 --dist loadfile -vv"
|
||||
# Real PowerShell/process-tree tests share the hosted runner's
|
||||
# Windows console. Separate xdist workers can therefore deliver a
|
||||
# control event across worker boundaries; run this compatibility
|
||||
# matrix serially, as nanobot itself does in one client process.
|
||||
pytest_args: "--full-trace"
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
|
||||
@@ -896,6 +896,7 @@ class TestWindowsRealExec:
|
||||
@pytest.mark.asyncio
|
||||
async def test_windows_powershell_session_output_is_utf8(self):
|
||||
manager = ExecSessionManager()
|
||||
try:
|
||||
result = await ExecTool(timeout=180, session_manager=manager).execute(
|
||||
command="Start-Sleep -Milliseconds 1500; Write-Output 'café λ 你好'",
|
||||
shell="powershell",
|
||||
@@ -923,3 +924,5 @@ class TestWindowsRealExec:
|
||||
assert "café λ 你好" in result
|
||||
assert "Exit code: 0" in result
|
||||
assert "\x00" not in result
|
||||
finally:
|
||||
await manager.close_all()
|
||||
|
||||
Reference in New Issue
Block a user