KB Article KA18720
Visible to All Users

Coded UI Test Extension FAQ

Description:
Starting with version 12.1, the DevExpress WinForms controls provide Coded UI Tests support. This article answers frequently asked questions related to CUIT support in our controls, licensing issues and troubleshooting solutions.

Answer:
Important note:
Officially, we support Coded UI Test Extension and recommend using it to create automated tests for our desktop components. However, according to the recent Microsoft announcements (see Visual Studio 2019 Preview Release Notes), Visual Studio 2019 will be the final version of Visual Studio with Coded UI test features. According to Microsoft's recommendations, you can use Selenium for testing web-applications and Appium with WinAppDriver for testing desktop and UWP apps. Although we don't declare official support for these testing tools, our research showed that these testing tools can be used with our components.

1) What is the Coded UI Test Extension?
The Coded UI Test Extension for DevExpress WinForms controls is an extension to Microsoft CUIT tailored to facilitate UI testing in DevExpress WinForms controls using the Microsoft CUIT framework. Refer to the Microsoft CUITarticle to learn how to record your first UI test.
2) How can I get Coded UI tests to work with DevExpress WinForms controls? Should I install a specific extension to get it to work?
Yes. For Coded UI Tests to recognize our controls, you need to install the DevExpress Coded UI Test Extension (CUIT Extension) for WinForms Controls, shipped as a part of the Universal subscription.
3) What controls and actions does the DevExpress CUIT Extension support?
There are four levels of Coded UI support. All DevExpress WinForms controls provide support for Microsoft Coded UI Tests (CUIT) level 1. The list of controls that support level 2 and higher is available in the Coded UI Test Extension: Supported Controls and Actions help topic.
4) What IDE and tools do I need to use the DevExpress CUIT Extension?
It is necessary to use Microsoft Visual Studio 2010 Premium/Ultimate/Test Professional edition (Service Pack 1), Microsoft Visual Studio 2012 Premium/Ultimate/Test Professional edition, Microsoft Visual Studio 2013 Premium/Ultimate/Test Professional edition, or Microsoft Visual Studio 2015 Enterprise edition. Refer to the Coded UI Test Extension: System Requirements help topic for more information.
5) What subscription do I need to use the CUIT Extension?
The CUIT Extension is a part of the Universal subscription. With other subscriptions, the CUIT Extension can be installed in Trial mode. So, you can test them even if you don't have the Universal subscription.
6) I do not develop applications, I only test applications using your controls. Should I have a separate Universal subscription to create Coded UI tests for these applications?
To use the CUIT Extension on a test machine, you need to have a separate valid Universal license for each tester.
If you do not have Visual Studio installed on a test machine and use Microsoft Test Manager to build and run tests, you also need to have a separate license for each tester to use the CUIT Extension.
For more information about the CUIT Extension licensing policy, contact us at management@devexpress.com.
7) Do you have an installer that only installs the CUIT Extension, so that I can use it on a test machine without installing your controls?
In v.21.2 and higher, the Coded UI Test Extensions for WinForms installer was removed from the download list. According to Microsoft documentation, some Coded UI test features are still supported in Visual Studio 2022 and higher and it's possible to run Coded UI tests. However, Visual Studio 2019 is the last version to provide test creation via the recorder. Only basic minimal support for Coded UI Test is available in Visual Studio 2022 (see the Use Coded UI tests to test your code article for details). According to Microsoft's recommendations, you can use Selenium for testing web-applications and Appium with WinAppDriver for testing desktop and UWP apps.
At present, it is necessary to install WinForms components using the Universal Unified Component installer.
As for older versions, a separate installer for the CUIT Extension is available for Universal subscription owners. You can download it from the Download Manager.
As mentioned above, the .NET Controls and Libraries installer also installs the CUIT Extension.
So, there is no need to run a separate installer for the CUIT Extension on a machine where .NET Controls are already installed.
For more information on the CUIT Extension installer, refer to Julian Bucknall’s blog post: Separate Installation of Coded UI Test Extension for WinForms Controls.
To uninstall the Coded UI extension of any version, we prepared a small WinForms project: RemoveCodedUIExtension.zip. Should you face any difficulties, feel free to contact us in this regard.
8) How can I check to see if the extension is registered properly?
When you create a new Coded UI test, the CUIT Extension assembly should automatically be added to the project's References section.
9) I can't get your extension to work. What should I do?
First, ensure that your system meets the System Requirements for the CUIT Extension.
If you installed Visual Studio after installing the CUIT Extension, run the CUIT Extension installation again in Repair mode.
The minor version of the CUIT Extension must be the same as the minor version of the DevExpress WinForms controls used in your application, or installed on the test machine. However, you can still use multiple major versions on a single machine.
All installation processes are written to an installation log file. For.NET products, it is located in the .NET Controls and Libraries installation folder you specified during the installation. For the separate Coded UI Test Extension installer, the path is %ProgramFiles%\DevExpress XX.Y\DevExpressCodedUIExtensions. If you have any issues, refer to that file to view the errors that occurred during installation.
If the information above doesn't help, please run the attached BAT file, which will collect more information about your system. Send us the generated log file so that we can research this issue.
10) How can I check if your controls are recognized properly?
When you create an Assert method, the Technology property in the PropertyGrid should display "DevExpress". In addition, all classes generated for the DevExpress WinForms controls should start with the "DX" prefix.
11) I copied the assembly with the CUIT Extension on my machine and added a reference to it in the project References section, but DevExpress WinForms controls are not recognized properly. Why?
The CUIT Extension should be installed to the GAC and registered in a special manner on your machine. The .NET Controls and Libraries and the separate Coded UI Test Extension installers do this automatically. Please refer to the “Hello, World” Extension for Coded UI Test blog post to learn more on how to register a custom CUIT Extension.

Show previous comments (5)
Alisher (DevExpress Support) 8 years ago

    Hello Przemysław,

    Thank you for your feedback.

    You are right; the Professional edition of Visual Studio does not have Coded UI Testing. In the answer to question 3, Visual Studio Test Professional edition is mentioned. This edition, however, does have Coded UI Testing. Please review the Software Testing for Professionals | Visual Studio page for more information.

    Let me know if you have additional questions.

    GS GS
    Ghislain Sommervogel 6 years ago

      Hi Team,

      Just reacting to Gosha's statement about Appium/WinAppDriver compatibility
      "Although we don't declare official support for these testing tools, our research showed that these testing tools can be used with our components."

      I'm currently working on automating tests with Appium/WinAppDriver. It's working fine with many devexpress controls, but is not compatible with the spreadhsheetcontrol. The lower object in hierarchy appears to be the spreadsheet control itself and not the grid cells. It is therefore not possible to automate a cell selection.

      I've attached a screenshot taken from Visual UI Automation Verify (from Windows 10 SDK) to illustrate the issue. Below the spreadsheet control, you can only access the tabs bar and the lateral scrollbars. Not the worksheets themselves, nor the cells. A similar object tree is produced by Inspect.exe (also Windows 10 SDK) or by WinAppDriverUiRecorder.exe (another advanced tool to locate elements to automate). At the time beeing, no test automation is therefore possible on this control.

      … but for you to feel confortable with it, Microsoft Excel doesn't allow test automation using WinAppDriver either (AFAIK).

      That beeing said, I would be very interested in having an extended DevExpress compatibility with Appium/WinAppDriver in the next few monthes. Even if I have to go through the Universal Extension in order to get it!

      Cheers,
      Ghislain

      DevExpress Support Team 6 years ago

        Hello Ghislain,

        Thank you for your feedback. The Appium/WinAppDriver support is currently under consideration and that is why we cannot guarantee that these tests will work for all our components as expected.
        As for extending the compatibility with our components, I cannot provide you with a definite time frame as to when we provide it. If you are interested in it, I suggest that you follow our blogs and announcements.

        Disclaimer: The information provided on DevExpress.com and affiliated web properties (including the DevExpress Support Center) is provided "as is" without warranty of any kind. Developer Express Inc disclaims all warranties, either express or implied, including the warranties of merchantability and fitness for a particular purpose. Please refer to the DevExpress.com Website Terms of Use for more information in this regard.

        Confidential Information: Developer Express Inc does not wish to receive, will not act to procure, nor will it solicit, confidential or proprietary materials and information from you through the DevExpress Support Center or its web properties. Any and all materials or information divulged during chats, email communications, online discussions, Support Center tickets, or made available to Developer Express Inc in any manner will be deemed NOT to be confidential by Developer Express Inc. Please refer to the DevExpress.com Website Terms of Use for more information in this regard.