Skip to content
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

Add support for testing unpackaged WinUI applications #2784

Open
Evangelink opened this issue Apr 30, 2024 · 5 comments
Open

Add support for testing unpackaged WinUI applications #2784

Evangelink opened this issue Apr 30, 2024 · 5 comments

Comments

@Evangelink
Copy link
Member

Evangelink commented Apr 30, 2024

Results of my investigations on the WinUI issue #1127 (comment) are showing that we now work correctly for all cases but unpackaged applications. Although, this is not a work related to MSTest, I want to keep track of this missing feature.

AB#2050311

@michael-hawker
Copy link

michael-hawker commented Apr 30, 2024

Thanks @Evangelink, is there an issue tracking this in the WinAppSDK repo we can link to?

Also, copying your matrix here and formatting as a table:

WindowsAppSDKSelfContained Not set True False
WindowsPackageType Not set None MSIX Not set None MSIX Not set None MSIX
Result with VSTest

And the resulting error for the None WindowsPackageType:

File name: 'C:\src\temp\MSTestWinUI\UnitTest\bin\x64\Debug\net6.0-windows10.0.19041.0\win10-x64\AppxManifest.xml'
   at System.IO.__Error.WinIOError(Int32 errorCode, String maybeFullPath)
   at System.IO.FileStream.Init(String path, FileMode mode, FileAccess access, Int32 rights, Boolean useRights, FileShare share, Int32 bufferSize, FileOptions options, SECURITY_ATTRIBUTES secAttrs, String msgPath, Boolean bFromProxy, Boolean useLongPath, Boolean checkHost)
   at System.IO.FileStream..ctor(String path, FileMode mode, FileAccess access, FileShare share, Int32 bufferSize)
   at System.Xml.XmlDownloadManager.GetStream(Uri uri, ICredentials credentials, IWebProxy proxy, RequestCachePolicy cachePolicy)
   at System.Xml.XmlUrlResolver.GetEntity(Uri absoluteUri, String role, Type ofObjectToReturn)
   at System.Xml.XmlTextReaderImpl.FinishInitUriString()
   at System.Xml.XmlReaderSettings.CreateReader(String inputUri, XmlParserContext inputContext)
   at System.Xml.Linq.XDocument.Load(String uri, LoadOptions options)
   at Microsoft.VisualStudio.UwpTestHostRuntimeProvider.AppxManifestFile.ReadTargetPlatformVersions()
   at Microsoft.VisualStudio.UwpTestHostRuntimeProvider.AppxManifestFile.get_TargetPlatformVersion()
   at Microsoft.VisualStudio.UwpTestHostRuntimeProvider.Deployer.Microsoft.VisualStudio.UwpTestHostRuntimeProvider.IDeployer.get_TargetPlatformVersion()
   at Microsoft.VisualStudio.UwpTestHostRuntimeProvider.UwpTestHostManager.<LaunchHostAsync>d__36.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at Microsoft.VisualStudio.UwpTestHostRuntimeProvider.UwpTestHostManager.<Microsoft-VisualStudio-TestPlatform-ObjectModel-Host-ITestRuntimeProvider-LaunchTestHostAsync>d__28.MoveNext()<---

@Evangelink
Copy link
Member Author

Thanks @Evangelink, is there an issue tracking this in the WinAppSDK repo we can link to?

Not yet. I am still discussing some details but I will post here the ticket or info once it's sorted.

@Evangelink Evangelink self-assigned this May 2, 2024
@Evangelink Evangelink added this to the 3.5.0 milestone May 2, 2024
@testplatform-bot
Copy link
Contributor

✅ Successfully linked to Azure Boards work item(s):

@Evangelink
Copy link
Member Author

Postponing to next iteration as there were many bug fixes to handle this sprint.

@Evangelink
Copy link
Member Author

Postponing to wait for availability from WinUI team.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants