Version 8.0.1 |
As this approach is quite difficult to understand just by reading,
we describe a sample implementation using the "CarConfigurator Web" demo in this
section. You can find the "CarConfigurator Web" test suite at
qftest-8.0.1/demo/carconfigWeb/carconfigWeb_en.qft
.
Figure 50.8: CarConfigurator Web |
As stated in the previous section we need to figure out which attribute provides the required information. This information will then be used to point to a generic class of QF-Test.
As shown in the previous sections our first task for testing web-projects is to figure out how QF-Test recognizes the components and to create a corresponding dictionary. This task looks rather difficult at the first glance, but its result will drastically reduce the maintenance work due to component changes or hierarchy changes in later stages of your project. This is because QF-Test uses the relevant properties of your HTML components only, and not any information available.
chapter 60 shows a full list of all generic classes for standard components and complex components like lists or trees. We recommend that you map only those components which are really required and not every existing component. It's rather simple to extend the mechanism later.
Repeating the steps of the previous example
we would now continue to map other components like menu items or tabs.
As the mapping would be too much for this manual we provided a full sample
in the demo test suite
qftest-8.0.1/demo/carconfigWeb/carconfigWeb_en.qft
in the procedure startStop.start
in the last sequence,
Install CustomWebResolver
.
In order to use the created dictionary at every start of your web application you should
move the 'Install CustomWebResolver' node into
your 'Setup' node directly after launching the browser.
In case you created the 'Setup' node via the Quickstart Wizard,
you will find the node in the sequence
Install CustomWebResolver
that can be configured accordingly.
Besides the pure translation of web page specifics into QF-Test classes, it's also
possible to ignore certain components during recording.
This is done via the categories ignoreTags
and ignoreByAttributes
.
However, you should do this only after you mapped most of the business components.
Finally, we would like to show the differences in the recording of the component tree as it was originally and after implementing the 'CustomWebResolver' as in the demo test case of the demo test suite. The figure below shows the recording without any resolvers on the left and the simplified tree on the left.
| |||||||
Figure 50.18: Simplification of the "CarConfigurator Web" demo |
Last update: 9/10/2024 Copyright © 1999-2024 Quality First Software GmbH |
1. Cookies fonctionnels
Nous utilisons des cookies fonctionnels pour garantir la fonctionnalité de base du site web.
2. Cookies de performance et de statistique
Nous utilisons Matomo pour analyser et améliorer notre site web. Des cookies permettent une collection anonyme des informations qui nous aident à vous offrir un visite clair et facile à utiliser de nos pages web.
This cookie contains a unique, pseudonymized visitor ID internal to Matomo for recognizing repeat visitors.
This cookie is used to track from which website the anonymized user proceeded to any page or sub-page.
The Matomo session cookie is used to track the visitor's page requests during the session. The cookie is automatically deleted at the end of each session (website visit), at the latest after one day.
is created and should be then directly deleted (used to check whether the visitor’s browser supports cookies).
short lived cookies used to temporarily store data for the visit.
short lived cookies used to temporarily store data for the visit.