Version 7.1.5 SWT45.2SWT instrumentation Some special setup is required for testing SWT based applications with QF-Test/swt. Because SWT was not written with testability in mind, applications need to be run with a few slightly modified SWT classes in which we have added the necessary hooks for event filtering and component tracking to enable testing. The changes are transparent so that the…
Version 7.1.5 3.1+52.7Test run listeners Once registered with the current run context via rc.addTestRunListener, an implementation of the TestRunListener interface will get notified whenever test execution enters or exits a node and when a problem occurs. An illustrative example is provided in the test suite TestRunListener.qft, located in the directory demo/runlistener in your QF-Test…
Version 7.1.5 47.2Timing Besides component recognition, timing is an inherently difficult problem in automatic testing. No two runs of a Java program are identical when it comes to timing. Too much depends on things like system load or memory usage. This can lead to a situation where a target component for an event is not available, because the VM is still busy popping up the dialog window that…
Version 7.1.5 50.2Example Please find the sample test suites in the subdirectories demo/carconfigWpf and demo/carconfigForms of the QF-Test installation directory. 50.2.1Starting the application The sample test suites use the dependency SUT_started in the package qfs.autowin.dependencies of the standard library to start the demo application. The node Execute shell command actually starts the demo.…
Version 7.1.5 49.3Browser connection mode QF-Test has three different modes to gain access to a browser. This section describes these modes in details. 4.1+ Given that the QF-Driver approach using embedding is not maintained anymore by some browser vendors or is not supported at all, a new mechanism was implemented for QF-Test 4.1 to support future browsers and browser versions. This mechanism…
Version 7.1.5 4.1+52.12WebDriver SUT API The WebDriverConnection SUT API provides classes and interfaces to enable using Selenium WebDriver Java API inside a 'SUT script'. With this kind of bridge you can use your existing Selenium WebDriver scripts inside a 'SUT script' of QF-Test. You can even combine the Pseudo DOM API (section 52.11) with Selenium WebDriver based scripts. NoteThis API is only…
Version 7.1.5 5.0+52.13Windows Control API The elments of native Windows applications are represented during a test by Java objects of the class WinControl. This class provides several public methods, e.g. to develop custom resolvers. 52.13.1The WinControl class Following is a list of the methods of the WinControl class in alphabetical order. WinControl getAncestorByUiaType(String typeName)…
Version 7.1.5 5.4.1Class The class of a component is a very important attribute as it describes the type of the recorded component. Once QF-Test records a button, it will only look for a button on replay, not for a table or a tree. Thus the component class conveniently serves to partition the components of a GUI. This improves performance and reliability of component recognition, but also helps…
Version 7.1.5 5.4.7Component hierarchy The nesting is used in 'Component event' for recognition as well. With 'Component' nodes, the containers of a component are recorded as well. Whether they should be used for recognition with a present 'Name' attribute can be controlled with the options Name override mode (replay) and Name override mode (record). The best setting for each is described in About…
Version 7.1.5 5.7Scope6.0+ A scope can be used to narrow the search area for components. This is useful to make component references unique or to improve the readability of a test. Example: There are three panels with address data with identically labeled text fields. The scope can now be set to one of the panels. Now the specified SmartIDs refer exclusively to the fields in this panel. Scope can…