1

Does CodedUI uses the Microsoft UI Automation for finding WPF controls and taking any action (like click or adding value to text box)? If not what is the difference between both.

The reason why I asked this question is, I am in middle of creating automated test cases for a WPF application which is using DevExpress controls and I'm currently using CodedUI for the same. But few days back I came to know (from one DevExpress support ticket), that DevExpress controls don't support CodedUI but they do support Microsoft UI Automation framework, and then I search for UI Automation and found some links which say that CodedUI uses UI Automation for WPF. So I created couple of test cases in both and found that it is more difficult (in terms of time) for CodedUI to locate elements than UI Automation.

But before moving all test cases from CodedUI to UI AUtomation (i.e. from Microsoft.VisualStudio.TestTools.UITesting.WpfControls to System.Windows.Automation) I want to make sure that UI Automation is the right option for me.

3
  • 1
    Possible duplicate of Coded UI vs Protractor
    – Bharat Mane
    Commented Apr 26, 2017 at 6:51
  • 1
    No it is not a duplicate. WPF is desktop application creation framework and DevExpress a UI-component-library. Commented Apr 26, 2017 at 7:40
  • 1
    Not a duplicate. This is about desktop UI automation and two different flavors of accessing components.
    – Kate Paulk
    Commented Apr 26, 2017 at 11:25

1 Answer 1

2

Seems Coded-UI does use UIA underneath, but also some other technology.

Coded-UI test is a Record & Play automation tool which uses the Microsoft UIA Library underneath. Since being a tool compared to writing code in C# it improves QA productivity for recording more test cases.

https://stackoverflow.com/questions/4909206/microsoft-ui-automation-library-vs-coded-ui-test

And this written by Microsoft employees

Just to be more specific, UIAutomation is an accessiblity technology. CodedUI Test is a test automation framework which supports various technologies like Web, Winforms, WPF, etc. It internally uses UIAutomation for certain plugins such as WPF to access the control properties/events, etc. More about CodedUI Test in the link provided above by Silviu. That's a good starting point.

https://social.msdn.microsoft.com/Forums/en-US/dcb986b3-9b01-4ff5-98f5-0e55f3201829/difference-between-coded-ui-and-ui-automation?forum=vsautotest

And

Coded UI Tests are a framework which wraps many automation technologies. UIA is just one of them.

https://stackoverflow.com/questions/5620406/what-is-the-difference-between-using-system-windows-automation-and-microsoft-visu

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.