There is an application with a GUI, which is written in JAVA.

Is it possible to programmatically interact with the program interface?

For example, to find elements on the form, to insert something into the TextBox, then click on the buttons.

Or at such a high level nothing can be done and you will have to know exactly where the element is and move the cursor with your hands?

What programs can explore the interface of the running application?

Is it possible to interact with CAV from JAVA from C #?

  • one
    Of course it is possible. Now I will find an example, I ran here once. - VladD
  • one
  • @VladD, and you can get the names of the controls through Inspect? - iluxa1810
  • What is meant by the name of the controllers? - Grundy
  • @Grundy, to click a button programmatically, I need to know what it is called? - iluxa1810

1 answer 1

Pay attention to the system of automated testing applications. A good article about them. There are a great many of them, there are expensive ones, there are open sources, for different platforms, etc. The most famous

  • MS Coded UI - for desktop applications
  • Selenium (for web applications)
  • Appium (for mobile applications)

All of them are based on some macro scripting languages, and one of the main tasks of these macro commands is to get into the controls with the help of a mouse, enter text, select options from lists, and so on, that is, emulate the work of real users.

The controls identify these systems in different ways:

  • fix their absolute and / or relative pixel coordinates (scripts in the end need to be developed for each screen size)

  • know identifiers - in web forms it seems to be

  • recognize by the screenshot - a text label, or adjacent elements, or the inscription on the button, etc.

If the program under study already exists and does not change during operation - the script needs to be written 1 time, it will expand the program to full screen and get perfectly well even without knowing the names of the controls (by coordinates).

If the program changes rapidly (especially in the part of UI) - QA automation scripts lose their value dramatically, the question of their relevance in general before UI stabilization is correct.

  • MS Coded UI tests are quite able to use Automation ID too. - VladD