1bf215546Sopenharmony_ci$dxil_dll = cmd.exe /C "C:\BuildTools\Common7\Tools\VsDevCmd.bat -host_arch=amd64 -arch=amd64 -no_logo && where dxil.dll" 2>&1
2bf215546Sopenharmony_ciif ($dxil_dll -notmatch "dxil.dll$") {
3bf215546Sopenharmony_ci    Write-Output "Couldn't get path to dxil.dll"
4bf215546Sopenharmony_ci    exit 1
5bf215546Sopenharmony_ci}
6bf215546Sopenharmony_ci$env:Path = "$(Split-Path $dxil_dll);$env:Path"
7bf215546Sopenharmony_ci
8bf215546Sopenharmony_ci# VK_ICD_FILENAMES environment variable is not used when running with
9bf215546Sopenharmony_ci# elevated privileges. Add a key to the registry instead.
10bf215546Sopenharmony_ci$hkey_path = "HKLM:\SOFTWARE\Khronos\Vulkan\Drivers\"
11bf215546Sopenharmony_ci$hkey_name = Join-Path -Path $pwd -ChildPath "_install\share\vulkan\icd.d\dzn_icd.x86_64.json"
12bf215546Sopenharmony_ciNew-Item -Path $hkey_path -force
13bf215546Sopenharmony_ciNew-ItemProperty -Path $hkey_path -Name $hkey_name -Value 0 -PropertyType DWORD
14bf215546Sopenharmony_ci
15bf215546Sopenharmony_ci$results = New-Item -ItemType Directory results
16bf215546Sopenharmony_ci$baseline = ".\_install\warp-fails.txt"
17bf215546Sopenharmony_ci$suite = ".\_install\deqp-dozen.toml"
18bf215546Sopenharmony_ci
19bf215546Sopenharmony_ci$env:DZN_DEBUG = "warp"
20bf215546Sopenharmony_ci$env:MESA_VK_IGNORE_CONFORMANCE_WARNING = "true"
21bf215546Sopenharmony_cideqp-runner suite --suite $($suite) --output $($results) --baseline $($baseline) --testlog-to-xml C:\deqp\executor\testlog-to-xml.exe --jobs 4 --fraction 3
22bf215546Sopenharmony_ci$deqpstatus = $?
23bf215546Sopenharmony_ci
24bf215546Sopenharmony_ci$template = "See https://$($env:CI_PROJECT_ROOT_NAMESPACE).pages.freedesktop.org/-/$($env:CI_PROJECT_NAME)/-/jobs/$($env:CI_JOB_ID)/artifacts/results/{{testcase}}.xml"
25bf215546Sopenharmony_cideqp-runner junit --testsuite dEQP --results "$($results)/failures.csv" --output "$($results)/junit.xml" --limit 50 --template $template
26bf215546Sopenharmony_ciCopy-Item -Path "C:\deqp\testlog.css" -Destination $($results)
27bf215546Sopenharmony_ciCopy-Item -Path "C:\deqp\testlog.xsl" -Destination $($results)
28bf215546Sopenharmony_ci
29bf215546Sopenharmony_ciif (!$deqpstatus) {
30bf215546Sopenharmony_ci    Exit 1
31bf215546Sopenharmony_ci}
32