3.15.9. Understanding the component hierarchy

The component hierarchy is designed to allow flexible test specification and robust tests.

Abstract components

You can write tests very abstractly at the beginning, only adding detail later. You will notice that the library contains categories such as Component with Text Input and Graphics Component.

These are abstract components – actions in these categories can be used on a wide range of actual components in the AUT. You can use a Click action on the Graphics Component to click any component in the AUT. You just need to enter different component names for it in the Component Names View.

Using the same component name for different component types

What happens if you want to specify a test that clicks in a table and then selects a cell in the table?

The click action is on the Graphics Component and the select cell action is on the Table component – but you don’t want to have two different component names.

This isn’t a problem. You can use the same component name for different components as long as these are compatible. So, in this case, the Graphics Component and the Table component can both use the component name e.g. TableView_MainTable_tbl.

You are allowed to use the same component name for incompatible types, but component names which have incompatible usage are marked by an "Incompatible usage type" error marker.

Also it is possible to map a component name to a component which does not realize one of the usages of the component name, but such component names are marked by an "Incompatible map type" error marker. For example a component name which is used in a JavaFX Tree Table action mapped into a Tree would have this marker.



Copyright BREDEX GmbH 2015. Made available under the Eclipse Public License v1.0.