ci(windows-smoke): start the app in the test step; log processes/ports
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01PPmy3tPq869XDW4njjVaKA
This commit is contained in:
co-authored by
Claude Opus 5.5
parent
0d86f19935
commit
a754bb0a93
@@ -84,16 +84,7 @@ jobs:
|
||||
if (-not (Test-Path $app)) { Write-Error "not installed at $app"; exit 1 }
|
||||
(Get-Item $app).VersionInfo | Select-Object ProductVersion, FileVersion
|
||||
|
||||
- name: Start the app with the WebView2 DevTools port open
|
||||
shell: powershell
|
||||
run: |
|
||||
$env:WEBVIEW2_ADDITIONAL_BROWSER_ARGUMENTS = '--remote-debugging-port=9222 --use-fake-device-for-media-stream'
|
||||
$app = Join-Path $env:LOCALAPPDATA 'Lotus Chat\cinny.exe'
|
||||
Start-Process $app
|
||||
Start-Sleep -Seconds 5
|
||||
Get-Process cinny | Select-Object Id, SessionId, MainWindowTitle
|
||||
|
||||
- name: Smoke test
|
||||
- name: Start the app and smoke test it
|
||||
shell: powershell
|
||||
run: |
|
||||
New-Item -ItemType Directory -Force -Path smoke-deps | Out-Null
|
||||
@@ -101,8 +92,20 @@ jobs:
|
||||
npm init -y | Out-Null
|
||||
npm install --no-audit --no-fund playwright-core@1 | Out-Null
|
||||
Pop-Location
|
||||
$env:NODE_PATH = (Resolve-Path smoke-deps\node_modules).Path
|
||||
Copy-Item scripts\windows-smoke.mjs smoke-deps\windows-smoke.mjs
|
||||
# Same step as the test: a process started in an earlier step may be
|
||||
# cleaned up when that step ends.
|
||||
$env:WEBVIEW2_ADDITIONAL_BROWSER_ARGUMENTS = '--remote-debugging-port=9222 --use-fake-device-for-media-stream'
|
||||
$app = Join-Path $env:LOCALAPPDATA 'Lotus Chat\cinny.exe'
|
||||
Start-Process $app
|
||||
Start-Sleep -Seconds 15
|
||||
Write-Host "--- processes"
|
||||
Get-Process cinny, msedgewebview2 -ErrorAction SilentlyContinue | Select-Object Name, Id, SessionId | Format-Table | Out-String | Write-Host
|
||||
Write-Host "--- listening ports 9222/44548"
|
||||
Get-NetTCPConnection -State Listen -ErrorAction SilentlyContinue | Where-Object { $_.LocalPort -in 9222, 44548 } | Select-Object LocalAddress, LocalPort, OwningProcess | Format-Table | Out-String | Write-Host
|
||||
Write-Host "--- WebView2 runtime"
|
||||
Get-ItemProperty 'HKLM:\SOFTWARE\WOW6432Node\Microsoft\EdgeUpdate\Clients\{F3017226-FE2A-4295-8BDF-00C3A9A7E4C5}' -ErrorAction SilentlyContinue | Select-Object pv | Out-String | Write-Host
|
||||
Write-Host "--- whoami: $(whoami)"
|
||||
node smoke-deps\windows-smoke.mjs smoke-out
|
||||
|
||||
- name: Stop the app
|
||||
|
||||
Reference in New Issue
Block a user