Converting Appium.Windows.Windows Element to Native UIA element
Is there way to convert : Microsoft.VisualStudio.TestTools.UITesting.UITestControl to OpenQA.Selenium.Appium.Windows.WindowsElement
Reason we are asking is, we have existing suite of automation developed in coded ui and wanted to migrate to WinAppdriver.
In Case we get stuck as as discussed in issue id 753, if there is option to convert Appium Windows element to UITestControl or Native object of UIAutomation Library, we can proceed further with custom code like below:
Where UIWindow.UICheckBoxListWindow.UIItemList is of type UITestControl
var native = UIWindow.UICheckBoxListWindow.UIItemList.NativeElement as object[]; if ((native != null) && (native[0] is IAccessible)) { var dataList = native[0] as IAccessible; for (var index = 1; index < dataList.accChildCount; index++) { actions.Add(dataList.accName[index]); } In other words getting access to Native Element from OpenQA.Selenium.Appium.Windows.WindowsElement
I am afraid not, you need to rewrite all the test cases.
We also have same issue and we are rewriting test cases as we did not find any solution.
Please refer to this article from the Coded UI team:
Migration There are no automated migration tools available to move from Coded UI test to Selenium or Appium at this time. We recommend that any new test collateral being built should use the alternatives and plan your replacement of older Coded UI tests so that it is completed before the end of the Visual Studio support lifecycle. As part of this process we recommend that customer re-evaluate their test portfolio to remove tests that are no-longer useful.
Premier support for Enterprise can be engaged for help with migrating tests to alternatives – they can be reached via email on [email protected]
I hope that this post is helpful in answering any questions you may have. If you have any further queries, please reach out to the team at [email protected].
For any migration inquiries, I recommend reaching out to the provided address above ^. Thanks.
what is the way to get native elements for appium web elemets in winappdriver
We also have same issue and we are rewriting test cases as we did not find any solution.
can you please suggest how you acheived the same