TestLoadedEvent fails in CI build (but not locally)
mgoertz-msft opened this issue · 5 comments
Describe the bug
Now that I have re-enabled the CI build pipeline in AzDO, the TestLoadedEvent fails for both net462 as well as net6.0. However, if I build and run the test locally on my machine it passes. Not sure yet what's going on or whether to even keep the tests running in the AzDO CI pipeline now that they are also running in the GH Action.
Reproduction Link
https://devdiv.visualstudio.com/DevDiv/_build/results?buildId=7614182&view=results
I do not have access to view those results, but my guess is that the Azure pipelines will need to be updated as well.
I see where it is still trying to use .NET 5.0.100 instead of 6.0.
Not to mention, it is running tests after it creates the nuget package LOL
Right, I updated all of that today. The only issue left now is this test failure, and this is all I get for it:
Failed TestLoadedEvent [118 ms]
Error Message:
Assert.AreEqual failed. Expected:<1>. Actual:<2>. GotMouseCapture action was invoked
Stack Trace:
at Microsoft.Xaml.Interactions.UnitTests.EventTriggerTest.TestLoadedEvent() in D:\a\_work\1\s\Test\UnitTests\EventTriggerTests.cs:line 391
I hate it when stuff like that happens.
Have you tried switching to use ‘dotnet test’ command instead of the VSTest action?
No, I haven't. But I have a feeling that it wouldn't help much because the test uses CaptureMouse() and that may not execute as expected in the AzDO agent pool. I think I'll try using a different event since capturing the mouse isn't essential to this test.
I also noticed that all our expected vs actual values for Assert.AreEqual are reversed. It works but it's confusing when something goes wrong. :-)
I also noticed that all our expected vs actual values for Assert.AreEqual are reversed. It works but it's confusing when something goes wrong
I noticed that too 😄