Windows 10 (UWP) Coded UI

2019-04-08 14:11发布

问题:

There is no Coded UI project in Visual Studio 2015 for UWP and I can't find any documentation anywhere saying there is a plan to bring support.

Does anyone know if there is planned support it or have some alternative UI testing framework to work with Windows Universal?

回答1:

I guess you can use this Coded UI Test Project (Universal Windows) which is under

File->New->Project->Templates->Windows->Universal-->Coded UI Test Project (Universal Windows)

for Coded UI project in Visual Studio 2015 for UWP.



回答2:

Maybe an important information for other to come is. That it’s not possible to create such projects in the community version of visual studio. You need at least the enterprise version as mentioned here.



回答3:

An update for anyone arriving at this question is that Microsoft are deprecating support for Coded UI testing after the Visual Studio 2019 release...

https://docs.microsoft.com/en-us/visualstudio/test/use-ui-automation-to-test-your-code?view=vs-2017

Coded UI Test for automated UI-driven functional testing is deprecated. Visual Studio 2019 is the last version where Coded UI Test will be available. We recommend using Selenium for testing web apps and Appium with WinAppDriver for testing desktop and UWP apps.

So, the suggested answer by Microsoft for automating UWP UI testing is to adopt Appium with WinAppDriver.