Test scripts shouldn’t know about test objects

When scripting desktop tests is a common practice to rely too much on script recorders, that will script automatically your test, based on mouse and keyboard activity. The main problem with the resulting scripts is that they are too coupled with the desktop interface and, therefore, difficult to maintain.

One of the main objectives that we are persuading when creating a testing framework for Ubuntu desktop is to avoid scripts to know anything about the objects behind them. Definitively, these objects will still require to be maintained, but the logic of the scripts will remain the same.

One example. Let’s imagine that we had a regression test suite for Gedit that will edit, modify, open and save several files. Many. About a hundred. If any of the Gedit features changes its UI, only the Gedit class will be modified. All the scripts will still be valid.

Decoupling scripts and test objects will also keep the door opened to Model-based Testing.

Comments are closed.