Should the GUI have their own automated tests?

Is there a reason for automating tests that focus on the graphical interface (rather than the things underneath)? In my opinion, the GUI (and changes to it) should always be checked by a real person.

What can you get with automated graphical tests? My own experience was that GUI focus tests almost always break down because someone changed something for a really good reason. It seems that they are rarely interesting.

+7
testing automated-tests
source share
9 answers

It is not simple. Automated testing tools and wireframes do an excellent job and cost time and effort until the GUI changes too much. The problem with automated testing is that it breaks down exactly when you need it most: when the GUI changes quickly during the development cycle.

As a result, I decided to use a hybrid approach for projects that I lead and manage. I like to use manual testing on areas of the GUI that change quickly during the development cycle. Once the situation is quite stable, we do some kind of automatic testing of the graphical interface (for example, Selenium for web applications), which we introduce into the assembly process to protect against future regression. If at all possible, QA people write automated tests. Sometimes developers have to contact QA testers to do this when the automated tool is too intense for the code.

This hybrid approach seems to work well, as long as we use good design methods that separate cares properly so that unit tests can properly use all the underlying logic. The only thing you should avoid is interweaving the application logic into a GUI layer.

+4
source share

It depends.

If your GUI is a relatively thin layer above your business logic, and minor bugs in the GUI are not critical to your business, then you can not waste time testing your GUI with unit tests. Perhaps then it would be better to invest in testing more critical code.

If your GUI is very complex and a big selling point for your application, then you might want to invest time in testing it both automatically and manually. Automatic testing does not completely replace manual testing, as you still need human testers to make sure that the graphical interface looks right and that the interface is intuitive.

For more information on testing GUIs, see Wikipedia , for example, by entering key input and key input and playback. There is also a list of software that can help you when creating tests for GUI modules.

+2
source share

Depends on the β€œwhat” part of the GUI you are testing. You check the behavior of the system using the GUI test or want to check if your graphical interface is displayed correctly at any time.

In the latter case, it depends on your application. If the layout and design is an importer, I agree. However, if this is an application in which the main functionality is not the layout itself, it makes no sense to invest time to test the layout. It would be better to write a GUI test that tests functionality using a graphical interface rather than some function calls. Thus, real behavior is better modeled.

0
source share

People do a great job testing GUIs. They are expensive. Automated testing tools theoretically at least reduce the cost of testing user interfaces. If you release frequently, the time for manual testing of the interface can very quickly go through the roof.

I personally have never seen automated user interface testing tools pay for their installation costs for the projects I've been to. Their tests tend to be fragile and do not respond very well to layout changes. For this reason, I hesitate to trust them. I would be happy if I were mistaken.

0
source share

It is possible. For the browser, you have test suits, such as selenium, that interact with the browser.

0
source share

My approach in this situation usually refers to unit test non-GUI layers, makes maximum use of automatic testing of the graphical interface, and then manually checks everything that remains. I also use manual testing to detect ad-hoc defects to identify missing test cases.

For me, this provides the best ratio of test coverage to cost. Ultimately, it depends on what you are trying to achieve - is it critical software or a simple application, where failure is just an inconvenience?

0
source share

You better give the first usability test. Also, how are you going to test a single GUI? What will be the way out? If someone clicks and gets something that he "originally" looked for? What should be considered unacceptable behavior?

You will get tons of pawnshop to watch. Usability is a big word, but a simple test for usability is to hire your friend (preferably not the one you know, friend of a friend) that you can consider in the target audience. Turning on the camera / camstudio (desktop recording software, it might be nice to record his face). Give him some tasks on a piece of paper (or in person, sometimes paper is better because you will not interfere - a more realistic scenario). And watch what he does!

If he requires help, you will see sections on future development. Never try to influence a guy who tells him things like "but look at this button, I thought it was more convenient."

You will get a much better result from such a test, instead of wasting time testing from computer to computer. GUI - INTERFACE between a person and a computer. Gui's group testing is like trying to parse the book you just wrote and see how good it is. Of course, this will eliminate spelling errors, for example, but this is a very small thing β†’ compared to the real goals of the book.

0
source share

Yes, of course, the GU should have its own unit tests. See for example IcuTest .

The problem is that the complexity of GUI testing . When you have it, the world will be yours.

0
source share

If you have repetitive monotonous tasks in testing the graphical interface, and you need to do this for several combinations of browsers and OS, then it is worth automating the graphical interface. Using support methods, an answer can be given to the well-known question: "Changes to the user interface will make automation impossible."

0
source share

All Articles