From f478533db98327ad6fe1accecab7a2aa04a4b8b0 Mon Sep 17 00:00:00 2001 From: Leilei Zhang Date: Fri, 18 Jul 2025 11:40:39 +0800 Subject: [PATCH] update reg --- .pipelines/v2/templates/job-test-project.yml | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/.pipelines/v2/templates/job-test-project.yml b/.pipelines/v2/templates/job-test-project.yml index 6b52351222..1942d2af2d 100644 --- a/.pipelines/v2/templates/job-test-project.yml +++ b/.pipelines/v2/templates/job-test-project.yml @@ -113,6 +113,23 @@ jobs: & '$(build.sourcesdirectory)\.pipelines\InstallWinAppDriver.ps1' displayName: Download and install WinAppDriver + - pwsh: |- + # Set Windows Error Reporting to not show UI to prevent test hangs + reg add "HKLM\SOFTWARE\Microsoft\Windows\Windows Error Reporting" /v DontShowUI /t REG_DWORD /d 1 /f + Write-Host "Windows Error Reporting DontShowUI set to prevent dialog popups during UI tests" + displayName: Configure Windows Error Reporting for UI Tests + + - pwsh: |- + # Verify the setting was actually applied + $result = reg query "HKLM\SOFTWARE\Microsoft\Windows\Windows Error Reporting" /v DontShowUI 2>$null + if ($result -match "DontShowUI.*REG_DWORD.*0x1") { + Write-Host "✓ Verification successful: DontShowUI is set to 1" + } else { + Write-Host "✗ Verification failed: DontShowUI setting not found or incorrect" + Write-Host "Registry query result: $result" + } + displayName: Verify Windows Error Reporting Configuration + - ${{ if eq(parameters.useLatestOfficialBuild, true) }}: - task: DownloadPipelineArtifact@2 inputs: