Skip to content

Flaky tests: Microsoft.AspNetCore.Components.E2ETests #29553

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
halter73 opened this issue Jan 22, 2021 · 4 comments · Fixed by #32283
Closed

Flaky tests: Microsoft.AspNetCore.Components.E2ETests #29553

halter73 opened this issue Jan 22, 2021 · 4 comments · Fixed by #32283
Assignees
Labels
area-blazor Includes: Blazor, Razor Components Done This issue has been fixed task test-failure
Milestone

Comments

@halter73
Copy link
Member

halter73 commented Jan 22, 2021

Example failure:

CanInvokeDotNetMethods

OpenQA.Selenium.BrowserAssertFailedException : Xunit.Sdk.NotEmptyException: Assert.NotEmpty() Failure
   at Xunit.Assert.NotEmpty(IEnumerable collection) in C:\Dev\xunit\xunit\src\xunit.assert\Asserts\CollectionAsserts.cs:line 331
   at Microsoft.AspNetCore.E2ETesting.WaitAssert.<>c__DisplayClass15_0.<Exists>b__0() in /_/src/Shared/E2ETesting/WaitAssert.cs:line 72
   at Microsoft.AspNetCore.E2ETesting.WaitAssert.<>c__DisplayClass18_0`1.<WaitAssertCore>b__0(IWebDriver ) in //src/Shared/E2ETesting/WaitAssert.cs:line 109
Screen shot captured at 'F:\workspace\_work\1\s\artifacts\TestResults\Release\Microsoft.AspNetCore.Components.E2ETests\1d1f4408eb7d409183a8e135bc9d9119.png'
Encountered browser errors
[2021-01-22T13:59:50Z] [Debug] http://127.0.0.1:53114/subdir/_framework/dotnet.6.0.0-alpha.1.21061.20.js 0:140953 "mono_wasm_runtime_ready" "fe00e07a-5519-4dfe-b35a-f867dbaf2e28"
[2021-01-22T13:59:51Z] [Info] http://127.0.0.1:53114/subdir/_framework/blazor.webassembly.js 0:44430 "Starting interop invocations."
[2021-01-22T13:59:51Z] [Info] http://127.0.0.1:53114/subdir/js/jsinteroptests.js 6:12 "Invoking void sync methods."
[2021-01-22T13:59:51Z] [Severe] http://127.0.0.1:53114/subdir/_framework/blazor.webassembly.js 0:44469 "crit: Microsoft.AspNetCore.Components.WebAssembly.Rendering.WebAssemblyRenderer[100]
Unhandled exception rendering component: Expected string argument
Error: Expected string argument
    at Object.js_string_to_mono_string (http://127.0.0.1:53114/subdir/_framework/dotnet.6.0.0-alpha.1.21061.20.js:1:171532)
    at Object.converter_ssss [as compiled_function] (https://mono-wasm.invalid/converter_ssss:19:18)
    at managed__Microsoft_AspNetCore_Components_WebAssembly__Microsoft_AspNetCore_Components_WebAssembly_Services_DefaultWebAssemblyJSRuntime_InvokeDotNet (https://mono-wasm.invalid/managed__Microsoft_AspNetCore_Components_WebAssembly__Microsoft_AspNetCore_Components_WebAssembly_Services_DefaultWebAssemblyJSRuntime_InvokeDotNet:10:33)
    at Object.invokeDotNetFromJS (http://127.0.0.1:53114/subdir/_framework/blazor.webassembly.js:1:51643)
    at p (http://127.0.0.1:53114/subdir/_framework/blazor.webassembly.js:1:2157)
    at Object.e.invokeMethod (http://127.0.0.1:53114/subdir/_framework/blazor.webassembly.js:1:3273)
    at Object.invokeDotNetInteropMethodsAsync (http://127.0.0.1:53114/subdir/js/jsinteroptests.js:8:12)
    at http://127.0.0.1:53114/subdir/_framework/blazor.webassembly.js:1:3942
    at new Promise (\u003Canonymous>)
    at Object.beginInvokeJSFromDotNet (http://127.0.0.1:53114/subdir/_framework/blazor.webassembly.js:1:3908)
Microsoft.JSInterop.JSException: Expected string argument
Error: Expected string argument
    at Object.js_string_to_mono_string (http://127.0.0.1:53114/subdir/_framework/dotnet.6.0.0-alpha.1.21061.20.js:1:171532)
    at Object.converter_ssss [as compiled_function] (https://mono-wasm.invalid/converter_ssss:19:18)
    at managed__Microsoft_AspNetCore_Components_WebAssembly__Microsoft_AspNetCore_Components_WebAssembly_Services_DefaultWebAssemblyJSRuntime_InvokeDotNet (https://mono-wasm.invalid/managed__Microsoft_AspNetCore_Components_WebAssembly__Microsoft_AspNetCore_Components_WebAssembly_Services_DefaultWebAssemblyJSRuntime_InvokeDotNet:10:33)
    at Object.invokeDotNetFromJS (http://127.0.0.1:53114/subdir/_framework/blazor.webassembly.js:1:51643)
    at p (http://127.0.0.1:53114/subdir/_framework/blazor.webassembly.js:1:2157)
    at Object.e.invokeMethod (http://127.0.0.1:53114/subdir/_framework/blazor.webassembly.js:1:3273)
    at Object.invokeDotNetInteropMethodsAsync (http://127.0.0.1:53114/subdir/js/jsinteroptests.js:8:12)
    at http://127.0.0.1:53114/subdir/_framework/blazor.webassembly.js:1:3942
    at new Promise (\u003Canonymous>)
    at Object.beginInvokeJSFromDotNet (http://127.0.0.1:53114/s


   at Microsoft.AspNetCore.E2ETesting.WaitAssert.WaitAssertCore[TResult](IWebDriver driver, Func`1 assertion, TimeSpan timeout) in /_/src/Shared/E2ETesting/WaitAssert.cs:line 129
   at Microsoft.AspNetCore.E2ETesting.WaitAssert.Exists(IWebDriver driver, By finder, TimeSpan timeout) in /_/src/Shared/E2ETesting/WaitAssert.cs:line 67
   at Microsoft.AspNetCore.Components.E2ETest.Tests.InteropTest.CanInvokeDotNetMethods() in /_/src/Components/test/E2ETest/Tests/InteropTest.cs:line 137
----- Inner Stack Trace -----
   at Microsoft.AspNetCore.E2ETesting.WaitAssert.<>c__DisplayClass15_0.<Exists>b__0() in /_/src/Shared/E2ETesting/WaitAssert.cs:line 72
   at Microsoft.AspNetCore.E2ETesting.WaitAssert.<>c__DisplayClass18_0`1.<WaitAssertCore>b__0(IWebDriver _) in /_/src/Shared/E2ETesting/WaitAssert.cs:line 109

https://dev.azure.com/dnceng/public/_build/results?buildId=961819&view=ms.vss-test-web.build-test-results-tab&runId=30306712&resultId=100473&paneView=debug

https://dev.azure.com/dnceng/public/_build/results?buildId=961240&view=ms.vss-test-web.build-test-results-tab&runId=30294640&resultId=100388

https://dev.azure.com/dnceng/public/_build/results?buildId=961243&view=ms.vss-test-web.build-test-results-tab&runId=30294740&resultId=100524

@halter73
Copy link
Member Author

The latest aspnetcore-ci run had 7 different Selenium tests fail with similar errors. I'm now wondering if it was the right move to quarantine CanInvokeDotNetMethods (#29554).

https://dev.azure.com/dnceng/public/_build/results?buildId=962800&view=results

@halter73
Copy link
Member Author

I've already started rerunning the tests since it's blocking a dependency update PR, but there are more failures at https://dev.azure.com/dnceng/public/_build/results?buildId=961819&view=logs&j=6c33d704-163a-5170-38fa-caa7bc99f17c&t=4a2ac175-72f0-54eb-c8b6-eb1e5d86c7d5&s=b49e7e65-b64b-557c-018e-3fd79c15ded6

@halter73 halter73 changed the title Flaky test: InteropTest.CanInvokeDotNetMethods() Flaky tests: Microsoft.AspNetCore.Components.E2ETests Jan 23, 2021
@mkArtakMSFT mkArtakMSFT added this to the Next sprint planning milestone Jan 25, 2021
@ghost
Copy link

ghost commented Jan 25, 2021

Thanks for contacting us.
We're moving this issue to the Next sprint planning milestone for future evaluation / consideration. We will evaluate the request when we are planning the work for the next milestone. To learn more about what to expect next and how this issue will be handled you can read more about our triage process here.

@HaoK
Copy link
Member

HaoK commented Mar 23, 2021

Maybe be good candidates for p2w

@HaoK HaoK self-assigned this Mar 23, 2021
@HaoK HaoK modified the milestones: 6.0-preview4, 6.0-preview5 Apr 19, 2021
@HaoK HaoK removed their assignment Apr 20, 2021
@TanayParikh TanayParikh self-assigned this Apr 21, 2021
@mkArtakMSFT mkArtakMSFT added the INTERNAL: Debug This label is used to scope experiments with bot automation, so that we can try out queries. label Apr 23, 2021
@TanayParikh TanayParikh added Working and removed INTERNAL: Debug This label is used to scope experiments with bot automation, so that we can try out queries. labels Apr 29, 2021
@ghost ghost added Done This issue has been fixed and removed Working labels Apr 29, 2021
@ghost ghost locked as resolved and limited conversation to collaborators May 29, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
area-blazor Includes: Blazor, Razor Components Done This issue has been fixed task test-failure
Projects
None yet
Development

Successfully merging a pull request may close this issue.

6 participants