Skip to main content
new tag ms-uiatomation should be used here as it will not confuse with questions relating to general UI Automation
Link
Tweeted twitter.com/#!/StackSQA/status/500727767991083008
Source Link

.Net GUI testing of third party components

Recently I have started to create a prototype automated test for a .net based desktop application. Our team uses at-least two third party components which I cannot reach with the MS UIAutomation framework. The tree just ends with the pane which implements the third party components and elements within seem to be unreachable for the automation framework.

enter image description here

In the screen-shot you see the VisualUIAVerifyNative.exe tool (which is included in the Windows SDK 8.1) has the Lassale AddFlow component selected in our application. The object tree just ends and the box element named "Initial" is not available to interact with. (Having used Selenium in the past it feels weird you cannot access all the elements)

My current fall-back is image based testing (finding a partial image within the current view), find the elements coordinates and use the mouse to select it and the keyboard to interact with it. This works, but this feels like a hackish workaround and very time consuming if the style of the application changes.

I expect I am not the first who is running into issues with creating automated tests with MS UIAutomation and third party components.

What is the best practice in a situation like this, is it possible to find the elements in another way? (Or are there other better frameworks for this?)