Skip to content

Commit

Permalink
[js/web] dump debug logs for karma for diagnose purpose (#19785)
Browse files Browse the repository at this point in the history
### Description
dump debug logs for karma for diagnose purpose.

This is for debugging the CI issue of Chrome launch failure and
considered temporary.
  • Loading branch information
fs-eire committed Mar 6, 2024
1 parent 1bfc266 commit a788514
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 6 deletions.
3 changes: 3 additions & 0 deletions js/web/script/test-runner-cli.ts
Original file line number Diff line number Diff line change
Expand Up @@ -569,6 +569,9 @@ async function main() {
if (webnn) {
chromiumFlags.push('--enable-experimental-web-platform-features');
}
if (process.argv.includes('--karma-debug')) {
karmaArgs.push('--log-level debug');
}
karmaArgs.push(`--bundle-mode=${args.bundleMode}`);
karmaArgs.push(...chromiumFlags.map(flag => `--chromium-flags=${flag}`));
if (browser.startsWith('Edge')) {
Expand Down
12 changes: 6 additions & 6 deletions tools/ci_build/github/azure-pipelines/templates/win-web-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -153,31 +153,31 @@ jobs:
errorActionPreference: stop
displayName: 'Pack NPM packages'
- script: |
npm test -- -e=chrome -b=webgl,wasm
npm test -- -e=chrome -b=webgl,wasm --karma-debug
workingDirectory: '$(Build.SourcesDirectory)\js\web'
displayName: 'Run ort-web tests (wasm,webgl backend)'
condition: eq('${{ parameters.RunWebGpuTests }}', 'false')
- script: |
npm test -- -e=chrome -b=webgl,wasm,webgpu $(webgpuCommandlineExtraFlags)
npm test -- -e=chrome -b=webgl,wasm,webgpu --karma-debug $(webgpuCommandlineExtraFlags)
workingDirectory: '$(Build.SourcesDirectory)\js\web'
displayName: 'Run ort-web tests (ALL backends)'
condition: eq('${{ parameters.RunWebGpuTests }}', 'true')
- script: |
npm test -- suite1 -e=chrome -b=webgpu --io-binding=gpu-tensor $(webgpuCommandlineExtraFlags)
npm test -- suite1 -e=chrome -b=webgpu --io-binding=gpu-tensor --karma-debug $(webgpuCommandlineExtraFlags)
workingDirectory: '$(Build.SourcesDirectory)\js\web'
displayName: 'Run ort-web tests (Suite1, webgpu, IO-binding=gpu-tensor)'
condition: eq('${{ parameters.RunWebGpuTests }}', 'true')
- script: |
npm test -- suite1 -e=chrome -b=webgpu --io-binding=gpu-location $(webgpuCommandlineExtraFlags)
npm test -- suite1 -e=chrome -b=webgpu --io-binding=gpu-location --karma-debug $(webgpuCommandlineExtraFlags)
workingDirectory: '$(Build.SourcesDirectory)\js\web'
displayName: 'Run ort-web tests (Suite1, webgpu, IO-binding=gpu-location)'
condition: eq('${{ parameters.RunWebGpuTests }}', 'true')
- script: |
npm test -- --webgl-texture-pack-mode -b=webgl -e=chrome
npm test -- --webgl-texture-pack-mode -b=webgl -e=chrome --karma-debug
workingDirectory: '$(Build.SourcesDirectory)\js\web'
displayName: 'Run ort-web tests - WebGL: packed mode'
- script: |
npm test -- --wasm-enable-proxy -b=wasm -e=chrome
npm test -- --wasm-enable-proxy -b=wasm -e=chrome --karma-debug
workingDirectory: '$(Build.SourcesDirectory)\js\web'
displayName: 'Run ort-web tests - WebAssembly: proxy'
condition: and(succeeded(), eq('${{ parameters.BuildConfig }}', 'Release'))
Expand Down

0 comments on commit a788514

Please sign in to comment.