[browser] fix WBT EventPipeDiagnosticsTests timing#123977
[browser] fix WBT EventPipeDiagnosticsTests timing#123977pavelsavara merged 16 commits intodotnet:mainfrom
Conversation
There was a problem hiding this comment.
Pull request overview
This PR addresses timing issues in the EventPipeDiagnosticsTests for WebAssembly builds by introducing delays to ensure proper event sequencing and test reliability.
Changes:
- Modified the
IncrementCountmethod in the Counter page to be asynchronous with a 1ms delay - Added a 500ms delay before exit in the test to ensure diagnostic upload completes
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 1 comment.
| File | Description |
|---|---|
| src/mono/wasm/testassets/BlazorBasicTestApp/App/Pages/Counter.razor | Changed IncrementCount to async method with minimal delay |
| src/mono/wasm/Wasm.Build.Tests/Blazor/EventPipeDiagnosticsTests.cs | Added delay before exit to allow diagnostic upload to complete |
src/mono/wasm/Wasm.Build.Tests/Blazor/EventPipeDiagnosticsTests.cs
Outdated
Show resolved
Hide resolved
|
What does this fix? I cannot see any issues on |
This comment was marked as outdated.
This comment was marked as outdated.
src/mono/wasm/Wasm.Build.Tests/Blazor/EventPipeDiagnosticsTests.cs
Outdated
Show resolved
Hide resolved
src/mono/wasm/testassets/BlazorBasicTestApp/App/Pages/Counter.razor
Outdated
Show resolved
Hide resolved
|
Here we go again log |
src/mono/wasm/Wasm.Build.Tests/Blazor/EventPipeDiagnosticsTests.cs
Outdated
Show resolved
Hide resolved
src/mono/wasm/Wasm.Build.Tests/Blazor/EventPipeDiagnosticsTests.cs
Outdated
Show resolved
Hide resolved
src/mono/wasm/Wasm.Build.Tests/Blazor/EventPipeDiagnosticsTests.cs
Outdated
Show resolved
Hide resolved
…s.cs Co-authored-by: Copilot <[email protected]>
…s.cs Co-authored-by: Copilot <[email protected]>
src/mono/wasm/Wasm.Build.Tests/Blazor/EventPipeDiagnosticsTests.cs
Outdated
Show resolved
Hide resolved
src/mono/wasm/Wasm.Build.Tests/Blazor/EventPipeDiagnosticsTests.cs
Outdated
Show resolved
Hide resolved
src/mono/wasm/Wasm.Build.Tests/Blazor/EventPipeDiagnosticsTests.cs
Outdated
Show resolved
Hide resolved
|
| <WorkItemPrefix Condition="'$(WasmEnableWebcil)' == 'false'">NoWebcil-</WorkItemPrefix> | ||
| <WorkItemPrefix Condition="'$(WasmFingerprintAssets)' == 'false'">NoFingerprint-</WorkItemPrefix> | ||
| <WorkItemPrefix Condition="'$(WasmBundlerFriendlyBootConfig)' == 'true'">JavascriptBundler-</WorkItemPrefix> | ||
| <WorkItemPrefix Condition="'$(TestUsingWorkloads)' == 'true'">WBT-Workloads-</WorkItemPrefix> |
There was a problem hiding this comment.
Why do we need the info here as well?
RuntimeFlavor is carried in separate Helix property as well as Scenario=WBT
There was a problem hiding this comment.
I did this to have prefix like WBT-NoWebcil-MONO-ST-Wasm.Build.Tests
https://helix.dot.net/api/jobs/316a0832-3a4a-4505-a1c4-bec361bd32c4/workitems?api-version=2019-06-17
Is this wrong place ?
There was a problem hiding this comment.
There was a problem hiding this comment.
job name propagates to asset links and that's a good thing
https://helixr1107v0xdcypoyl9e7f.blob.core.windows.net/dotnet-runtime-refs-pull-123977-merge-316a08323a4a4505a1/WBT-NoWebcil-MONO-ST-Wasm.Build.Tests/1/console.54e6b7ad.log?helixlogtype=result
There was a problem hiding this comment.
That's interesting, thank you.
Could we unify WBT/BuildWasmApps?
Do we have mono/coreclr prefixes for lib tests as well?
Should we include OS as well?
There was a problem hiding this comment.
Could we unify WBT/BuildWasmApps?
You mean naming ? Sure, go ahead.
Do we have mono/coreclr prefixes for lib tests as well?
Yes
https://helix.dot.net/api/jobs/86b502da-1c55-444c-ac54-2d5d4932b6f2/details?api-version=2019-06-17
https://helix.dot.net/api/jobs/86b502da-1c55-444c-ac54-2d5d4932b6f2/workitems/WasmTestOnChrome-CLR-ST-IcuAppLocal.Tests?api-version=2019-06-17
Should we include OS as well?
Good idea.

Fix: do let Playwright await promises - it blocks EP.
Other:
CpuProfileTestlocal methods to convey work they're doing.SetupCounterPageto decrease complexity of passes arguments.durationSeconds2->5 for sampling.