Package Documentation for QFS Standard Library qfs.qftQF-Test
Version 3.4.7
Summary
Test-suiteqfs.qft
Directory

This suite contains useful standard procedures provided and maintained by Quality First Software GmbH.

For a description of packages and procedures of this library in javadoc format, see qfs.html in the same directory.

Package overview
PackageDescription
Packageqfs
This package contains helpful standard procedures provided by Quality First Software.
Contains procedures to work with native windows of the operating system Windows.
Contain procedures to handle Adobe Acrobat Reader specific tasks like SaveAs or SaveAs Text ...
Packageawt
Procedures for advanced manipulation of awt components.
Procedures to select menu items.
Contains procedures to check components.
The procedures in this package are useful for generic cleanup after an exception is thrown.
Procedures for interacting with (SUT) clients.
Procedures to work with a QF-Test daemon.
Procedures to work with databases.
Procedures to bind data for data-driven testing.
Procedures for showing dialogs during the test-run.
Procedures for writing log-entries.
Procedures to write screenshots into the run-log.
Utility procedures for shell commands.
Procedures for advanced manipulation of swing components.
Procedures to set the state of checkboxes.
The procedures in this package are useful for generic cleanup after an exception is thrown.
Procedures to handle Comboboxes.
Procedures for accessing file chooser dialogs.
Procedures, which work for any Swing component.
Procedures for accessing lists.
Procedures for checking a list.
Procedures to (de-)select certain items of a list.
Procedures to select menu items and checkbox menu items.
Procedures for accessing standard error/message dialogs.
Procedures to select items and checkbox menu items from popup menus.
Procedures to access sliders.
Procedure for checking slider values.
 
Procedure to work with TabbedPanes.
Procedures to access tables.
Procedures to set the state of checkboxes in a table-cell.
Procedures for checking a table.
Procedures to (de-)select certain rows of a table.
Procedures to access text fields and text areas.
Procedures to access trees.
Procedures for checking a tree.
Packageswt
Procedures for advanced manipulation of SWT components.
Procedures to set the state of checkboxes.
The procedures in this package are useful for generic cleanup after an exception is thrown.
Procedures to handle Colordialogs.
Procedures to handle Comboboxes.
Procedures for SWT CTabFolder widgets.
Procedures for accessing directory dialogs.
Procedures for accessing file dialogs.
Procedures, which work for any SWT component.
Procedures for SWT instrumentation.
Procedures for accessing lists.
Procedures for checking a list.
Procedures to (de-)select certain items of a list.
Procedures to select menu items and checkbox menu items.
Procedures to select items and checkbox menu items from popup menus.
Procedures to work with sash components.
 
Procedures for SWT TabFolder widgets.
Procedures to access tables.
Procedures for checking a table.
Procedures to (de-)select certain rows of a table.
Procedures to access text fields and text areas.
Procedures to access trees.
Procedures for checking a tree.
Miscellaneous utility procedures.
Accessing the clipboard from procedures.
Procedures for sending E-Mails.
Procedures for interacting with a POP3 server.
Contain procedures to work with files.
Procedures for generating random string.
Procedures for handling the test execution.
Procedures for skipping test-steps.
Procedures for stopping test-steps.
Procedures for working with variables.
Packagexml
Procedures for working with XML files.
Packageweb
Web utility procedures.
AJAX procedures.
Browser procedures.
Procedures for handling Error-Dialogs opened within the Browser.
Packagedom
Procedures for handling DOM access.
General browser procedures.
Mozilla utility procedures.
The procedures in this package are useful for customizing browser settings.
Procedures to set the state of checkboxes.
Procedures for handling different web checks.
Procedures, which work for any Web component.
Procedures to access INPUT elements.
Procedures to access text fields and text areas.
Package overview
Package/Procedure/DependencyDescription
Packageqfs
This package contains helpful standard procedures provided by Quality First Software.
Contains procedures to work with native windows of the operating system Windows.
Contain procedures to handle Adobe Acrobat Reader specific tasks like SaveAs or SaveAs Text ...
Save the current open PDF in Adobe Acrobat Reader as a text file with the given filename.
Save the current open PDF in Adobe Acrobat Reader as a PDF file with the given filename.
Check, whether a native window on the operating system Windows is opened.
Check, whether a native window on the operating system Windows is opened and close it.
Close a window.
Read the URL from an InternetExplorer window.
Write all children of a window to the run-log.
Perform Ctrl+A and then Ctrl+C to a given window.
Mark and copy the whole text of a given document via Ctrl+A and Ctrl+C.
Packageawt
Procedures for advanced manipulation of awt components.
Procedures to select menu items.
Select an item from a menu.
Contains procedures to check components.
Check the state of a given component.
Check if given component is selected.
Check the text of a given component.
Compare two values for their equality.
Compare two values for their equality.
Compare two values for their equality.
The procedures in this package are useful for generic cleanup after an exception is thrown.
Close all dialogs.
Close all menus unconditionally.
Close all modal dialogs.
This procedure encompasses the usage of other cleanup procedures in this package and is the recommended operation to perform after an exception occurs and is implicitly caught.
Procedures for interacting with (SUT) clients.
Rename an SUT client.
Write a string to the stdin stream of a process started by QF-Test.
Helper method for turning on internal logging.
Helper method for turning off internal logging.
Procedures to work with a QF-Test daemon.
Starts remote instrumentation procedure for an Eclipse/RCP based or standalone SWT application via a given daemon.
Locate all running daemons and writes them into the run-log and prints a list of running daemons to the terminal.
Start a client application on a remote host via the QF-Test daemon.
Procedures to work with databases.
Build up connection to a given database and executes a specified select-sql-statement.
Build up connection to a given database and execute a specified SQL-statement.
Procedures to bind data for data-driven testing.
Create and register a databinder that binds a list of values to a variable.
Create and register a databinder that binds a list of value-sets to a set of variables.
Procedures for showing dialogs during the test-run.
Show a configurable dialog equivalent to JOptionPane.
Show an information dialog with an OK option.
Show an information dialog with a YES, NO and CANCEL option.
Show an information dialog with a YES and NO option.
Procedures for writing log-entries.
Write an error into the run-log.
Write a message into the run-log.
Write a warning into the run-log.
Procedures to write screenshots into the run-log.
Return the total number of monitors.
Write an image of a component into the run-log.
Write a screenshot of the whole screen into the run-log.
Write a screenshots of a given monitor into the run-log.
Utility procedures for shell commands.
Copy a given file or directory to a given target.
Delete a file.
Check whether a given file or directory exists.
Return the basename of the given file or directory.
Return the parent directory of the given file or directory.
Create a given directory.
Move a given file or directory to a given target.
Remove a given directory.
Create a given file or update the last modified date of an existing file.
Procedures for advanced manipulation of swing components.
Procedures to set the state of checkboxes.
Deselect a checkbox .If the checkbox is already de-selected, no action is performed.
Select a checkbox.
Procedureset
Set checkbox to the given state.
The procedures in this package are useful for generic cleanup after an exception is thrown.
Close all dialogs.
Close all menus unconditionally.
Close all modal dialogs.
This procedure encompasses the usage of other cleanup procedures in this package and is the recommended operation to perform after an exception occurs and is implicitly caught.
Procedures to handle Comboboxes.
Return the number of items of a given combo-box.
Select specified value of a given combobox.
Set a value in the combobox.
Select specified value of a given combobox using a SUT script.
Procedures for accessing file chooser dialogs.
Uninstall the JFileChooser name resolver.
Install the JFileChooser name resolver.
Select a file in a JFileChooser dialog.
Procedures, which work for any Swing component.
Click on a given component, but only if the according parameter is set to true.
Delete the current association of PriorityAwtSwingComponent.
Click on a given component.
Set the location of a given component.
Set a given component to the PriorityAwtSwingComponent.
Set the wdith and the height of a given component.
Procedures for accessing lists.
Procedures for checking a list.
Check the number of items of a given list according to a specified comparison mode.
Return the current index of a given item.
Return the number of items of a given list.
Return the text of a given item.
Procedures to (de-)select certain items of a list.
Deselect all items.
Deselect a given item, specified by its index.
Deselect a range of items, specified by their index.
Select all items.
Select a given item, specified by its index.
Select a range of items, specified by their index.
Select a given item by a mouse-click on it.
Procedures to select menu items and checkbox menu items.
Select an item from a menu.
Select an item within a submenu.
Select a checkbox menu item.
Select a checkbox menu item within within a submenu.
Procedures for accessing standard error/message dialogs.
Uninstall the JOptionPane name resolver.
Install the JOptionPane name resolver.
Procedures to select items and checkbox menu items from popup menus.
Select an item in a popup menu.
Select an item within a submenu of a popup menu.
Select a checkbox menu item in a popup menu.
Select a checkbox menu item within a submenu of a popup menu.
Procedures to access sliders.
Procedure for checking slider values.
Check the value of a slider component
Return the value of a slider component.
Set the value of a slider component.
 
Set delays for the QF-Test SUT initialization process.
Procedure to work with TabbedPanes.
Close a tab via clicking on the "X "button.
Select a tab in a given TabbedPane.
Procedures to access tables.
Procedures to set the state of checkboxes in a table-cell.
Deselect a checkbox in a table-cell .If the checkbox is already de-selected, no action is performed.
Select a checkbox in a table-cell.
Procedureset
Set checkbox in a table-cell to the given state.
Procedures for checking a table.
Check the number of rows of a given table according to a specified comparison mode.
Return the number of columns of a given table.
Return the current index of a given column.
Return the header text of a given column.
Return the number of rows of a given table.
Return the row number of a given cell.
Return the text of a given cell.
Rezise width of a table column.
Select a given cell.
Procedures to (de-)select certain rows of a table.
Deselect all rows.
Deselect a given row, specified by its index.
Deselect a range of rows, specified by their index.
Select all rows.
Select a given row, specified by its index.
Select a range of rows, specified by their index.
Procedures to access text fields and text areas.
Clear a multi-line text area.
Clear a simple text field.
Set a given text to a given text-field or text-area.
Read the content of a given file and set its content to a given text-field.
Procedures to access trees.
Example for a callback procedure used by expandNodes.
Procedures for checking a tree.
Check the number of visilble rows of a given tree according to a specified comparison mode.
Collapse a tree node.
Collapse a tree node.
Expand a tree node.
Expand a tree node.
Expand a tree node recursively.
Return the current index of a given node.
Return the number of rows of a given tree.
Return the text of a given node.
Select a given node.
Packageswt
Procedures for advanced manipulation of SWT components.
Procedures to set the state of checkboxes.
Deselect a checkbox .If the checkbox is already de-selected, no action is performed.
Select a checkbox.
Procedureset
Set checkbox to the given state.
The procedures in this package are useful for generic cleanup after an exception is thrown.
Close all modal dialogs.
Close all menus unconditionally.
This procedure encompasses the usage of other cleanup procedures in this package and is the recommended operation to perform after an exception occurs and is implicitly caught.
Procedures to handle Colordialogs.
Select a specified color of a ColorDialog.
Procedures to handle Comboboxes.
Return the number of items of a given combo-box.
Select specified value of a given combobox using a selection event.
Select specified value of a given combobox using a SUT script.
Procedures for SWT CTabFolder widgets.
This procedure raises an error, if a given tab is not dirty.
Close a tab in a generic CTabFolder that is identified only by the fact that it contains the desired tab.
Open the View Menu for a generic CTabFolder that is identified only by the fact that it contains the desired tab.
Select a tab in a generic CTabFolder that is identified only by the fact that it contains the desired tab.
Procedures for accessing directory dialogs.
Select a directory in a DirectoryDialog dialog.
Procedures for accessing file dialogs.
Select a file in a FileDialog dialog.
Procedures, which work for any SWT component.
Click on a given component, but only if the according parameter is set to true.
Delete the current association of PrioritySwtComponent.
Click on a given component.
Set the location of a given component.
Set a given component to the PrioritySwtWidget.
Set the wdith and the height of a given component.
Procedures for SWT instrumentation.
Instrument an Eclipse/RCP based or standalone SWT application for use with QF-Test.
Procedures for accessing lists.
Procedures for checking a list.
Check the number of items of a given list according to a specified comparison mode.
Return the number of items of a given list.
Return the text of a given item.
Procedures to (de-)select certain items of a list.
Deselect all items.
Deselect a given item, specified by its index.
Deselect a range of items, specified by their index.
Select all items.
Select a given item, specified by its index.
Select a range of items, specified by their index.
Select a given item by a mouse-click on it.
Procedures to select menu items and checkbox menu items.
Select an item from a menu.
Select an item within a submenu.
Select a checkbox menu item.
Select a checkbox menu item within within a submenu.
Procedures to select items and checkbox menu items from popup menus.
Select an item in a popup menu.
Select an item within a submenu of a popup menu.
Select a checkbox menu item in a popup menu.
Select a checkbox menu item within a submenu of a popup menu.
Procedures to work with sash components.
Move a sash by a given distance.
Move a sash to a given position.
 
Scroll a component one page downwards by simulating a hard mouse click below the scrollbar's thumb.
Scroll a component one page to the left by simulating a hard mouse click to the left of the scrollbar's thumb.
Scroll a component one page to the right by simulating a hard mouse click to the right of the scrollbar's thumb.
Scroll a component one page upwards by simulating a hard mouse click above the scrollbar's thumb.
Scroll a component downwards by simulating a hard mouse click on the down arrow button of its vertical scrollbar.
Scroll a component to the left by simulating a hard mouse click on the left arrow button of its horizontal scrollbar.
Scroll a component to the right by simulating a hard mouse click on the right arrow button of its horizontal scrollbar.
Scroll a component upwards by simulating a hard mouse click on the up arrow button of its vertical scrollbar.
Procedures for SWT TabFolder widgets.
Close a tab via sending a "close" selection event.
Select a tab in a given Tabfolder.
Procedures to access tables.
Procedures for checking a table.
Check the number of rows of a given table according to a specified comparison mode.
Return the number of columns of a given table.
Return the header text of a given column.
Return the number of rows of a given table.
Return the text of a given cell.
Select a given cell.
Procedures to (de-)select certain rows of a table.
Deselect all rows.
Deselect a given row, specified by its index.
Deselect a range of rows, specified by their index.
Select all rows.
Select a given row, specified by its index.
Select a range of rows, specified by their index.
Procedures to access text fields and text areas.
Clear a multi-line text area.
Clear a simple text field.
Set a given text to a given text-field or text-area.
Read the content of a given file and set its content to a given text-field.
Procedures to access trees.
Example for a callback procedure used by expandNodes.
Procedures for checking a tree.
Check the number of visilble rows of a given tree according to a specified comparison mode.
Collapse a tree node.
Collapse a tree node.
Expand a tree node.
Expand a tree node.
Expand a tree node recursively.
Return the number of rows of a given tree.
Return the text of a given node.
Select a given node.
Miscellaneous utility procedures.
Accessing the clipboard from procedures.
Return the current text on the system clipboard.
Trigger a full thread dump in the SUT if possible.
Dump the heap of the Java VM.
Procedures for sending E-Mails.
Procedures for interacting with a POP3 server.
Delete all messages from a pop3 account.
Fetch a message from a pop3 account.
Send an e-mail.
Send an e-mail.
Contain procedures to work with files.
Check, whether a given file contain a specific value.
Check, whether a given file contain a specific value in a line.
Return a date, default is the current date in current locale.
Return the time in the current format.
Return a timestamp, which reprents the current time in milliseconds.
Kill all running clients.
Kill a client.
Log all available methods of a given component.
Log current memory use.
Print a given message to STDOUT.
Print the content of a variable.
Procedures for generating random string.
Return a random string created of parts of a specified area.
Return a random number.
Return a random number between two given numbers.
Return a random string containing small letters.
Read the content of a given file.
Procedures for handling the test execution.
Procedures for skipping test-steps.
Skip the execution of the current test-case.
Skip the execution of the current test-set.
Procedures for stopping test-steps.
Stop the execution of the current test-case
Stop the complete test-run.
Stop the execution of the current test-set.
Procedures for working with variables.
Delete all global QF-Test variables.
Delete a given global QF-Test variable.
Write a given message into a given file.
Packagexml
Procedures for working with XML files.
Compare two XML files for full identity.
Packageweb
Web utility procedures.
AJAX procedures.
Installs a special resolver for given AJAX toolkit to improve recorded component types and hierarchy and therefore achieves improved component recognition.
Browser procedures.
Procedures for handling Error-Dialogs opened within the Browser.
Uses the Java AWT Robot Methods to automatically close an open Certificate Warning Dialog.
Uses the Java AWT Robot Methods to automatically close an open Javascript Warning Dialog.
Handle the native Windows Upload dialog (especially for Internet Explorer 8).
Packagedom
Procedures for handling DOM access.
Checks or unchecks all (enabled) Checkboxes which are situated in the DOM-Tree beneath the given Parent.
General browser procedures.
Check for the browser and if is not running than start it.
Checks if running Browser-Engine has embedded Internet Explorer 6.
Open a new window in an already running browser.
Show a different URL in an open browser window.
Ensures the given browser executable is started as a new process.
Mozilla utility procedures.
Check whether a Mozilla home directory contains the necessary GRE (Gecko Runtime Environment) files to allow testing.
The procedures in this package are useful for customizing browser settings.
Delete cookies.
Disable cookies in the browser.
Do startup settings for the browser.
Empty the browser cache.
Sets the Compatibility-Mode in Internet Explorer.
Enable cookies in the browser.
Enable/Disables the MutationListeners in the QF-Test browser engine for a specific document or globally for all documents.
Set preferred language for in the displaying web pages in the browser.
Set a proxy server for the browser.
Procedures to set the state of checkboxes.
Deselect a checkbox.
Select a checkbox.
Procedureset
Set checkbox to the given state.
Set all (enabled) checkboxes inside a given parent.
Procedures for handling different web checks.
Checks an attribute of a component.
Negates a normal Elementcheck in select elements to allow NegationChecks.
Checks if the given element (option-element-text) is in the select-element (combo-box).
Negates a normal WaitForComponentCheck to allow VisibilityChecks.
Negates a normal Textcheck to allow NegationChecks.
Checks the title of the BrowserWindow.
Procedures, which work for any Web component.
Click on a given component, but only if the according parameter is set to true.
Delete the current association of PriorityWebComponent.
Click on a given component.
Set a given component to the PriorityWebComponent.
Procedures to access INPUT elements.
Set the value of the INPUT:FILE node by whatever means that are applicable for the browser.
Procedures to access text fields and text areas.
Clear a multi-line text area.
Clear a simple text field.
Set a given text to a given text-field or text-area.
Read the content of a given file and set its content to a given text-field.
Details
Package: 'qfs'

This package contains helpful standard procedures provided by Quality First Software.

The "SUT client" name is used in many of the contained procedures represented by the "$(client)" variable. We recommend to define the variable "client" in the respective table of the test-suite's root node - as long as only one SUT client is used in the test-suite. This ensures that the "client" parameter doesn't have to be given separately.

Author:
QFS
Since:
1.05.0
Package: 'autowin'

Contains procedures to work with native windows of the operating system Windows.

All procedures use the Jython library autowin.py, located in the jython/Lib folder of the current installation. There are even more methods for your needs, e.g. click a button or setting a text.

Author:
QFS
Since:
3.1.4
Procedure/DependencyDescription
ProcedurecheckForExistence
Check, whether a native window on the operating system Windows is opened.
ProcedurecheckForExistenceAndClose
Check, whether a native window on the operating system Windows is opened and close it.
Procedureclose
Close a window.
ProceduregetURLFromIE
Read the URL from an InternetExplorer window.
ProcedurelogChildWindows
Write all children of a window to the run-log.
ProceduremarkAllAndCopy
Perform Ctrl+A and then Ctrl+C to a given window.
ProceduresaveTextToFileViaClipboard
Mark and copy the whole text of a given document via Ctrl+A and Ctrl+C.
Procedure: 'checkForExistence'

Check, whether a native window on the operating system Windows is opened. If the window is a result of your test you can configure it to provide an error or an exception, if the window does not appear.

Parameters:
title - The title of the window.
titleRegexp - true, if the given title is a regular expression, otherwise false.
errorLevel - MESSAGE if a message should be logged in case the window is not visible. WARNING if a warning should be logged in case the window is not visible. EXCEPTION if an exception should be raised in case the window is not visible. in any other case an error will be logged in case the window is not visible.
appearInReport - set this to 1, if you want to track a message or warning, which should also be part of the report later.
Exceptions:
UserException - if window is not visible and parameter errorLevel is set to EXCEPTION
Author:
QFS,mm
Since:
3.1.4
Procedure: 'checkForExistenceAndClose'

Check, whether a native window on the operating system Windows is opened and close it. If the window is a result of your test you can configure it to provide an error or an exception, if the window does not appear.

Parameters:
title - The title of the window.
titleRegexp - true, if the given title is a regular expression, otherwise false.
errorLevel - MESSAGE if a message should be logged in case the window is not visible. WARNING if a warning should be logged in case the window is not visible. EXCEPTION if an exception should be raised in case the window is not visible. in any other case an error will be logged in case the window is not visible.
appearInReport - set this to 1, if you want to track a message or warning, which should also be part of the report later.
Exceptions:
UserException - if window is not visible and parameter errorLevel is set to EXCEPTION
Author:
QFS,mm
Since:
3.1.4
Procedure: 'close'

Close a window.

Parameters:
title - The title of the window.
titleRegexp - true, if the given title is a regular expression, otherwise false
appearInReport - set this to 1, if you want to track a message or warning, which should also be part of the report later.
Author:
QFS,mm
Since:
3.1.4
Procedure: 'getURLFromIE'

Read the URL from an InternetExplorer window.

Parameters:
title - The title of the window.
titleRegexp - true, if the given title is a regular expression, otherwise false.
Exceptions:
UserException - if the browser window is not visible or the URL cannot be determined.
Author:
QFS
Since:
3.2.0
Procedure: 'logChildWindows'

Write all children of a window to the run-log.

Parameters:
titleRe - The title of the window as regular expression.
Author:
QFS, rl
Since:
3.2.0
Procedure: 'markAllAndCopy'

Perform Ctrl+A and then Ctrl+C to a given window.

Afterwards you should have the text in the Clipboard, which enables you to insert the text somewhere for checking.

Parameters:
title - The title of the window.
titleRegexp - true, if the given title is a regular expression, otherwise false.
Exceptions:
UserException - if window is not visible
Author:
QFS,mm
Since:
3.4.0
Procedure: 'saveTextToFileViaClipboard'

Mark and copy the whole text of a given document via Ctrl+A and Ctrl+C. Then it fetches the text from the clipboard and saves it into a given file.

Parameters:
fileName - The filename to save.
title - The title of the window.
titleRegexp - true, if the given title is a regular expression, otherwise
Exceptions:
UserException - if window is not visible
Author:
QFS,mm
Since:
3.4.0
Package: 'acrobat'

Contain procedures to handle Adobe Acrobat Reader specific tasks like SaveAs or SaveAs Text ...

Author:
QFS
Since:
3.4.0
Procedure/DependencyDescription
ProceduresaveAsText
Save the current open PDF in Adobe Acrobat Reader as a text file with the given filename.
ProceduresavePDF
Save the current open PDF in Adobe Acrobat Reader as a PDF file with the given filename.
Procedure: 'saveAsText'

Save the current open PDF in Adobe Acrobat Reader as a text file with the given filename. Note: It simultates the required keystrokes to open the file dialog. Currently only the English and German versions of Adobe Acrobat Reader are supported. Logs an error if the file is already existing but parameter overwriteExistingFile is set to true.

Parameters:
fileName - The filename to save.
title - The title of the window.
titleRegexp - true, if the given title is a regular expression, otherwise false.
dialogTitle - The title of the 'save as...'-dialog.
timeout - Timeout for waiting to complete the save-operation.
overwriteExistingFile - If set to true an already existing file gets overwritten
Exceptions:
UserException - if window is not visible or the file is already existing
Author:
QFS,tm
Since:
3.4.0
Procedure: 'savePDF'

Save the current open PDF in Adobe Acrobat Reader as a PDF file with the given filename. Note: It simultates CTRL+SHIFT+S keystrokes to open the file dialog. Logs an error if the file is already existing but parameter overwriteExistingFile is set to true.

Parameters:
fileName - The filename to save.
title - The title of the window.
titleRegexp - true, if the given title is a regular expression, otherwise false.
dialogTitle - The title of the 'save as...'-dialog.
timeout - Timeout for waiting to complete the save-operation.
overwriteExistingFile - If set to true an already existing file gets overwritten
Exceptions:
UserException - if window is not visible or the file is already existing
Author:
QFS,tm
Since:
3.4.0
Package: 'awt'

Procedures for advanced manipulation of awt components.

Author:
QFS
Since:
2.1.0
Package: 'menu'

Procedures to select menu items.

(AWT components java.awt.MenuItem from java.awt.Menu)

Plain AWT Menus are not supported by QF-Test out of the box, but you can use the procedures of this package to work with those menus.

Author:
QFS
Since:
2.1.0
Procedure/DependencyDescription
ProcedureselectItem
Select an item from a menu.
Procedure: 'selectItem'

Select an item from a menu.

For example: for the "File" -> "Open" action, the label of "File" is the menu, and the label for "Open" is the item.

Parameters:
client - The name of the SUT client.
frame - The id of the frame, which contains the menu.
menu - The label of the menu, e.g. "File".
item - The label of menu item, e.g. "Open".
Author:
QFS
Since:
2.1.0
Package: 'check'

Contains procedures to check components.

Author:
QFS
Since:
2.1.0
Procedure/DependencyDescription
ProcedurecheckEnabledStatus
Check the state of a given component.
ProcedurecheckSelectedStatus
Check if given component is selected.
ProcedurecheckText
Check the text of a given component.
ProcedurecheckValueToBeEqual
Compare two values for their equality.
ProcedurecompareTwoNumbers
Compare two values for their equality.
ProcedurecompareTwoStringValues
Compare two values for their equality.
Procedure: 'checkEnabledStatus'

Check the state of a given component.

It writes an error into the run-log, if the check fails.

Parameters:
id - ID of the component.
enabled - true, if component should be enabled. otherwise, if component should be disabled.
throwExc - whether the check should throw an exception on failure.
reportName - the Name for the check in the report.
Author:
QFS
Since:
2.1.0
Procedure: 'checkSelectedStatus'

Check if given component is selected.

It writes an error into the run-log, if the check fails.

Parameters:
id - ID of the component.
selected - true, if component should be selected. otherwise, if component shouldn't be selected.
throwExc - whether the check should throw an exception on failure.
reportName - the Name for the check in the report.
Author:
QFS
Since:
2.1.0
Procedure: 'checkText'

Check the text of a given component.

It writes an error into the run-log, if the check fails.

Parameters:
id - ID of the component.
text - text, which should be checked.
regexp - if this value is set to true, the text will be checks as regular-expression.
negate - if, the check should check for anything but the given text.
nameCheckType - the value for "name of check-type" attribute.
throwExc - whether the check should throw an exception on failure.
reportName - the Name for the check in the report.
Author:
QFS
Since:
2.1.0
Procedure: 'checkValueToBeEqual'

Compare two values for their equality.

It uses the rc.checkEqual() method from QF-Test.

Parameters:
got - The got value for comparison.
expected - The expected value for comparison.
checkMessage - The message, which should be written into the run-log for that check.
errorLevel - The kind of error, which should be logged. Either EXCEPTION, ERROR, WARNING or MESSAGE.
appearInReport - Flag, whether to show check in report, if a message or warning are set as errorLevel. If this is set to 1, the check will be shown in the report.
Author:
QFS
Since:
3.1.1
Procedure: 'compareTwoNumbers'

Compare two values for their equality. Both values should be numbers.

It uses the rc.check() method from QF-Test.

Parameters:
got - The received value for comparison.
expected - The expected value.
checkMessage - The message, which should be written into the run-log for that check.
compareMode - The comparison mode. =, asserts got == expected <, asserts got < expected >, asserts got > expected <=, asserts got <= expected >=, asserts got >= expected
errorLevel - The kind of error, which should be logged. Either EXCEPTION, ERROR, WARNING or MESSAGE.
appearInReport - Flag, whether to show check in report, if a message or warning are set as errorLevel. If this is set to 1, the check will be shown in the report.
Exceptions:
UserException, - if wrong comparison mode has been set.
Author:
QFS
Since:
3.1.1
Procedure: 'compareTwoStringValues'

Compare two values for their equality. The values should be string values.

It uses the rc.check() method from QF-Test.

Parameters:
got - The received value for comparison.
expected - The expected value.
checkMessage - The message, which should be written into the run-log for that check.
compareMode - The comparison mode. =, asserts got == expected <, asserts got < expected >, asserts got > expected <=, asserts got <= expected >=, asserts got >= expected
errorLevel - The kind of error, which should be logged. Either EXCEPTION, ERROR, WARNING or MESSAGE.
appearInReport - Flag, whether to show check in report, if a message or warning are set as errorLevel. If this is set to 1, the check will be shown in the report.
Exceptions:
UserException, - if wrong comparison mode has been set.
Author:
QFS
Since:
3.1.1
Package: 'cleanup'

Deprecated.

The procedures in this package are useful for generic cleanup after an exception is thrown. In some cases a menu or modal dialog may have been left open, causing future events for the SUT to be blocked.

This package is deprecated because according cleanup-procedures are implemented in the qfs.swing resp. qfs.swt package. Please use the technology specific procedures.

Author:
QFS
Since:
1.05.0
Procedure/DependencyDescription
ProcedurecloseAllDialogs
Close all dialogs.
ProcedurecloseAllMenus
Close all menus unconditionally.
ProcedurecloseAllModalDialogs
Close all modal dialogs.
ProcedureimplicitExceptionHandler
This procedure encompasses the usage of other cleanup procedures in this package and is the recommended operation to perform after an exception occurs and is implicitly caught.
Procedure: 'closeAllDialogs'

Deprecated.

Close all dialogs.

Parameters:
client - The name of the SUT client.
maxDialogs - Maximum number of dialogs that are tried to be closed. (Optional, default 6)
Author:
QFS
Since:
1.05.0
Procedure: 'closeAllMenus'

Deprecated.

Close all menus unconditionally. A menu left open (or even just selected) will cause events for the SUT to be blocked. This procedure is recommened for cleanup after an exception occurs.

Parameters:
client - The name of the SUT client.
Author:
QFS
Since:
1.05.0
Procedure: 'closeAllModalDialogs'

Deprecated.

Close all modal dialogs. A modal dialog that is left open will cause events for the SUT to be blocked. Ensuring that modal dialogs are closed is a good operation to conduct in a setup/cleanup sequence.

Parameters:
client - The name of the SUT client.
maxDialogs - Maximum number of modal dialogs that are tried to be closed. (Optional, default 5)
Author:
QFS
Since:
1.05.0
Procedure: 'implicitExceptionHandler'

Deprecated.

This procedure encompasses the usage of other cleanup procedures in this package and is the recommended operation to perform after an exception occurs and is implicitly caught.

Calling this procedure should be the first step in the cleanup sequence of any Test node with the "Implicitly catch exceptions" attribute set.

Parameters:
client - The name of the SUT client.
Author:
QFS
Since:
1.05.0
Package: 'client'

Procedures for interacting with (SUT) clients.

Author:
QFS
Since:
3.4
Procedure/DependencyDescription
ProcedurerenameClient
Rename an SUT client.
ProceduresendInput
Write a string to the stdin stream of a process started by QF-Test.
ProcedurestartLogging
Helper method for turning on internal logging.
ProcedurestopLogging
Helper method for turning off internal logging.
Procedure: 'renameClient'

Rename an SUT client. This is especially useful when interacting with sub-processes of an SUT where you don't have full control over the client name during startup.

Parameters:
oldName - The current name of the client.
newName - The new name of the client.
trueName - An optional name to use for recording which may include variable syntax with escaped $, e.g. $$(subclient).
Author:
QFS
Since:
3.4
Procedure: 'sendInput'

Write a string to the stdin stream of a process started by QF-Test.

Parameters:
client - The name of the client.
input - The input to send
addNewline - Whether to append a line separator to the input.
Exceptions:
NoSuchClientException - If there is no such client.
UserException - It the output cannot be written.
Author:
QFS,gs
Since:
3.5
Procedure: 'startLogging'

Helper method for turning on internal logging. For QFS support and debugging use only.

Author:
QFS
Since:
3.4
Procedure: 'stopLogging'

Helper method for turning off internal logging. For QFS support and debugging use only.

Parameters:
dontcompactify - Whether to prevent the resulting log entry from compactification.
Author:
QFS
Since:
3.4
Package: 'daemon'

Procedures to work with a QF-Test daemon.

Author:
QFS
Since:
2.9.9
Procedure/DependencyDescription
ProcedureinstrumentRemoteSwt
Starts remote instrumentation procedure for an Eclipse/RCP based or standalone SWT application via a given daemon.
ProcedurelocateDaemons
Locate all running daemons and writes them into the run-log and prints a list of running daemons to the terminal.
ProcedurestartRemoteSUT
Start a client application on a remote host via the QF-Test daemon.
Procedure: 'instrumentRemoteSwt'

Starts remote instrumentation procedure for an Eclipse/RCP based or standalone SWT application via a given daemon.

Parameters:
daemonhost - The host name or IP address of the QF-Test daemon.
daemonport - The port where the daemon is listening.
sutdir - The installation directory of the SUT at the destination machine.
plugin - Optional: The specific plugin to instrument. Useful in case the directories are not layed out as expected.
Author:
QFS, gs
Since:
3.3.0
Procedure: 'locateDaemons'

Locate all running daemons and writes them into the run-log and prints a list of running daemons to the terminal. If no daemons can be found it logs an error.

Parameters:
timeout - Timeout for waiting for running daemons.
Author:
QFS
Since:
3.3.0
Procedure: 'startRemoteSUT'

Start a client application on a remote host via the QF-Test daemon.

Parameters:
daemonhost - The host name or IP address of the QF-Test daemon.
daemonport - The port where the daemon is listening.
commandline - The commandline used by the daemon to launch the client. Arguments containing spaces must be wrapped into quotes.
Author:
QFS
Since:
2.9.9
Package: 'database'

Procedures to work with databases.

Author:
QFS
Since:
2.1.0
Procedure/DependencyDescription
ProcedureexecuteSelectStatement
Build up connection to a given database and executes a specified select-sql-statement.
ProcedureexecuteStatement
Build up connection to a given database and execute a specified SQL-statement.
Procedure: 'executeSelectStatement'

Build up connection to a given database and executes a specified select-sql-statement. You can configure the procedure to store all results in a group QF-Test variable.

NOTE: The SQL-statement should be a select statement! NOTE: The class of the database driver must be either in QF-Test's plugin directory or in the CLASSPATH environment variable before QF-Test startup!

For more information about connection-strings please see www.connectionstrings.com.

Parameters:
driver - The class-name of the database driver.
connectionString - The connection-string to the database.
dbUser - The user for establishing database-connection.
dbPass - The password for establishing database-connection.
statement - The SQL-statement, it should be a select statement.
resultGroupName - If this name is specified the result is stored in a Propertygroup, which an be accessed via ${resultGroup:.}.
Returns:
Set a global variable "resultRows", which contains all result-rows. You can access this variable in any Server-script.
Exceptions:
TestException - If something went wrong with the database or execution of statement.
Author:
QFS
Since:
2.1.0
Procedure: 'executeStatement'

Build up connection to a given database and execute a specified SQL-statement.

NOTE: The class of the database driver must be either in QF-Test's plugin directory or in the CLASSPATH environment variable before QF-Test startup!

For more information about connection-strings please see www.connectionstrings.com.

Parameters:
driver - The class-name of the database driver.
connectionString - The connection-string to the database.
dbUser - The user for establishing database-connection.
dbPass - The password for establishing database-connection.
statement - The SQL-statement.
Returns:
result 1 If result has been executed, otherwise 0. (Only for backward compatibility.)
Exceptions:
TestException - If something went wrong with the database or execution of statement.
Author:
QFS
Since:
2.1.0
Package: 'databinder'

Procedures to bind data for data-driven testing.

Author:
QFS
Since:
2.2.0
Procedure/DependencyDescription
ProcedurebindList
Create and register a databinder that binds a list of values to a variable.
ProcedurebindSets
Create and register a databinder that binds a list of value-sets to a set of variables.
Procedure: 'bindList'

Create and register a databinder that binds a list of values to a variable.

Parameters:
varname - The name of the variable to bind to.
values - The values to bind.
separator - Optional separator character for splitting the values. Default is whitespace.
counter - Optional variable name for the iteration counter.
intervals - Optional ranges of indices, separated by comma, e.g. "0,2-3"
Author:
QFS
Since:
2.2.0
Procedure: 'bindSets'

Create and register a databinder that binds a list of value-sets to a set of variables.

Parameters:
loopname - The name for which to register the databinder.
varnames - The names of the variables to bind to.
values - The values to bind. Value-sets are separated by linebreaks.
separator - Optional separator charactor for splitting the varnames and value-sets. Default is whitespace.
counter - Optional variable name for the iteration counter.
intervals - Optional ranges of indices, separated by comma, e.g. "0,2-3"
Author:
QFS
Since:
2.2.0
Package: 'dialogs'

Procedures for showing dialogs during the test-run.

Author:
QFS
Since:
3.0
Procedure/DependencyDescription
ProcedureshowConfigurabableDialog
Show a configurable dialog equivalent to JOptionPane.
ProcedureshowInformationMessageDialog
Show an information dialog with an OK option.
ProcedureshowYes_No_Cancel_Dialog
Show an information dialog with a YES, NO and CANCEL option.
ProcedureshowYes_No_Dialog
Show an information dialog with a YES and NO option.
Procedure: 'showConfigurabableDialog'

Show a configurable dialog equivalent to JOptionPane.

Parameters:
title - The title of the dialog.
msg - The message to be shown.
timeout - The timeout for closing the dialog in ms. -1 means no timeout.
messagetype - The message type, one of ERROR_MESSAGE, INFORMATION_MESSAGE, WARNING_MESSAGE, QUESTION_MESSAGE, PLAIN_MESSAGE .
optiontype - The option type, one of DEFAULT_OPTION, YES_NO_OPTION, YES_NO_CANCEL_OPTION or OK_CANCEL_OPTION.
alwaysOnTop - Try to bring the dialog to front. Supported for JDKs >= 1.5.
Returns:
The code for the clicked button. 0 for YES/OK, 1 for NO, 2 for CANCEL, and -1 for timeout.
Author:
QFS
Since:
3.0
Procedure: 'showInformationMessageDialog'

Show an information dialog with an OK option.

Parameters:
title - The title of the dialog.
msg - The message to be shown.
timeout - The timeout for closing the dialog in ms. -1 means no timeout.
alwaysOnTop - Try to bring the dialog to front. Supported for JDKs >= 1.5.
Returns:
The code for the clicked button. 0 for OK and -1 for timeout.
Author:
QFS
Since:
3.0
Procedure: 'showYes_No_Cancel_Dialog'

Show an information dialog with a YES, NO and CANCEL option.

Parameters:
title - The title of the dialog.
msg - The message to be shown.
timeout - The timeout for closing the dialog in ms. -1 means no timeout.
alwaysOnTop - Try to bring the dialog to front. Supported for JDKs >= 1.5.
Returns:
The code for the clicked button. 0 for YES, 1 for NO, 2 for CANCEL and -1 for timeout or closed.
Author:
QFS
Since:
3.0
Procedure: 'showYes_No_Dialog'

Show an information dialog with a YES and NO option.

Parameters:
title - The title of the dialog.
msg - The message to be shown.
timeout - The timeout for closing the dialog in ms. -1 means no timeout.
alwaysOnTop - Try to bring the dialog to front. Supported for JDKs >= 1.5.
Returns:
The code for the clicked button. 0 for YES, 1 for NO and -1 for timeout.
Author:
QFS
Since:
3.0
Package: 'run-log'

Procedures for writing log-entries.

Author:
QFS
Since:
2.1.0
Procedure/DependencyDescription
ProcedurelogError
Write an error into the run-log.
ProcedurelogMessage
Write a message into the run-log.
ProcedurelogWarning
Write a warning into the run-log.
Procedure: 'logError'

Write an error into the run-log.

Parameters:
client - The name of the SUT client.
message - The message, which should be written.
withScreenshots - If true, try to take screenshots from individual SUT windows. Screenshots of the whole screen are taken in any case.
Author:
QFS
Since:
2.1.0
Procedure: 'logMessage'

Write a message into the run-log.

Parameters:
message - The message, which should be written.
dontcompactify - If true, the message will not be removed from the run-log. Use with care!
report - If true, the message will be shown in the report. Implies dontcompactify.
Author:
QFS
Since:
2.1.0
Procedure: 'logWarning'

Write a warning into the run-log.

Parameters:
message - The message, which should be written.
report - If true, the warning will be shown in the report.
Author:
QFS
Since:
2.1.0
Package: 'screenshots'

Procedures to write screenshots into the run-log.

Author:
QFS
Since:
3.0
Procedure/DependencyDescription
ProceduregetMonitorCount
Return the total number of monitors.
ProcedurelogImageOfComponent
Write an image of a component into the run-log.
ProcedurelogScreenshot
Write a screenshot of the whole screen into the run-log.
ProcedurelogScreenshotOfMonitor
Write a screenshots of a given monitor into the run-log.
Procedure: 'getMonitorCount'

Return the total number of monitors.

Parameters:
inSUT - Whether to take the screenshot in a SUT script. Should be true, if you start the SUT remotely.
Returns:
The total number of monitors.
Author:
QFS
Since:
3.0
Procedure: 'logImageOfComponent'

Write an image of a component into the run-log.

Parameters:
client - The name of the SUT client.
id - The ID of the component to be written into the run-log.
title - An optional title for the image.
dontcompactify - If true, the screenshot will not be removed from the run-log. Use with care!
report - If true, the screenshot will be shown in the report. Implies dontcompactify.
Author:
QFS
Since:
3.0
Procedure: 'logScreenshot'

Write a screenshot of the whole screen into the run-log.

Parameters:
inSUT - Whether to take the screenshot in a SUT script. Should be true, if you start the SUT remotely.
title - An optional title for the image.
dontcompactify - If true, the screenshot will not be removed from the run-log. Use with care!
report - If true, the screenshot will be shown in the report. Implies dontcompactify.
Author:
QFS
Since:
3.0
Procedure: 'logScreenshotOfMonitor'

Write a screenshots of a given monitor into the run-log.

Parameters:
monitor - The index of the monitor, the first one is 0, the second 1 etc.
inSUT - Whether to take the screenshot in a SUT script. Should be true, if you start the SUT remotely.
title - An optional title for the image.
dontcompactify - If true, the screenshot will not be removed from the run-log. Use with care!
report - If true, the screenshot will be shown in the report. Implies dontcompactify.
Author:
QFS
Since:
3.0
Package: 'shellutils'

Utility procedures for shell commands.

Author:
QFS
Since:
2.2
Procedure/DependencyDescription
Procedurecopy
Copy a given file or directory to a given target.
ProceduredeleteFile
Delete a file.
Procedureexists
Check whether a given file or directory exists.
ProceduregetBasename
Return the basename of the given file or directory.
ProceduregetParentdirectory
Return the parent directory of the given file or directory.
Proceduremkdir
Create a given directory.
Proceduremove
Move a given file or directory to a given target.
ProcedureremoveDirectory
Remove a given directory.
Proceduretouch
Create a given file or update the last modified date of an existing file.
Procedure: 'copy'

Copy a given file or directory to a given target. If the target is a directory, copy source into that directory. If target's parent directory does not exist, create it.

Parameters:
source - The source to be copied.
target - The target to be copied to.
Author:
QFS
Since:
2.2
Procedure: 'deleteFile'

Delete a file.

Parameters:
file - The file to remove.
Author:
QFS
Since:
2.2
Procedure: 'exists'

Check whether a given file or directory exists.

Parameters:
file - The path of the file or directory to check.
Returns:
exists true if file exists false if file does not exist
Author:
QFS
Since:
2.2
Procedure: 'getBasename'

Return the basename of the given file or directory. If the root directory is specified as parameter an empty string will returned.

Parameters:
file - The file or directory.
Returns:
The basename of the file or directory.
Author:
QFS
Since:
2.2
Procedure: 'getParentdirectory'

Return the parent directory of the given file or directory. If the root directory is specified as parameter an empty string will returned.

Parameters:
file - The file or directory.
Returns:
The parent directory of the file or directory.
Author:
QFS
Since:
2.2
Procedure: 'mkdir'

Create a given directory. It also creates non-existing parent directories.

Parameters:
directory - The directory to create.
Exceptions:
UserException, - if the directory couldn't be created
Author:
QFS
Since:
2.2
Procedure: 'move'

Move a given file or directory to a given target. If the target is a directory, copy source into that directory. If target's parent directory does not exist, create it. If an error happens during copying, source is not changed.

Parameters:
source - The source to be moved.
target - The target to be moved.
Author:
QFS
Since:
2.2
Procedure: 'removeDirectory'

Remove a given directory.

Parameters:
directory - The directory to remove.
Author:
QFS
Since:
2.2
Procedure: 'touch'

Create a given file or update the last modified date of an existing file.

For creation it also creates non-existing parent directories.

Parameters:
file - The file to touch.
Author:
QFS,mm
Since:
2.2
Package: 'swing'

Procedures for advanced manipulation of swing components.

Author:
QFS
Since:
1.05.0
Package: 'checkbox'

Procedures to set the state of checkboxes. (Swing component javax.swing.JCheckBox)

Author:
QFS
Since:
1.05.0
Procedure/DependencyDescription
Proceduredeselect
Deselect a checkbox .If the checkbox is already de-selected, no action is performed.
Procedureselect
Select a checkbox.
Procedureset
Set checkbox to the given state.
Procedure: 'deselect'

Deselect a checkbox .If the checkbox is already de-selected, no action is performed.

Parameters:
client - The name of the SUT client.
id - The id of the check-box.
Author:
QFS
Since:
1.05.0
Procedure: 'select'

Select a checkbox. If the checkbox is already selected, no action is performed.

Parameters:
client - The name of the SUT client.
id - The id of the check-box.
Author:
QFS
Since:
1.05.0
Procedure: 'set'

Set checkbox to the given state.

Parameters:
client - The name of the SUT client.
id - The id of the checkbox.
check - The check value to be set (either true or false).
Author:
QFS
Since:
1.05.0
Package: 'cleanup'

The procedures in this package are useful for generic cleanup after an exception is thrown. In some cases a menu or modal dialog may have been left open, causing future events for the SUT to be blocked.

Author:
QFS
Since:
2.1.0
Procedure/DependencyDescription
ProcedurecloseAllDialogs
Close all dialogs.
ProcedurecloseAllMenus
Close all menus unconditionally.
ProcedurecloseAllModalDialogs
Close all modal dialogs.
ProcedureimplicitExceptionHandler
This procedure encompasses the usage of other cleanup procedures in this package and is the recommended operation to perform after an exception occurs and is implicitly caught.
Procedure: 'closeAllDialogs'

Close all dialogs.

Parameters:
client - The name of the SUT client.
maxDialogs - Maximum number of dialogs that are tried to be closed. (Optional, default 6)
Author:
QFS
Since:
2.1.0
Procedure: 'closeAllMenus'

Close all menus unconditionally. A menu left open (or even just selected) will cause events for the SUT to be blocked. This procedure is recommened for cleanup after an exception occurs.

Parameters:
client - The name of the SUT client.
Author:
QFS
Since:
2.1.0
Procedure: 'closeAllModalDialogs'

Close all modal dialogs. A modal dialog that is left open will cause events for the SUT to be blocked. Ensuring that modal dialogs are closed is a good operation to conduct in a setup/cleanup sequence.

Parameters:
client - The name of the SUT client.
maxDialogs - Maximum number of modal dialogs that are tried to be closed. (Optional, default 5)
Author:
QFS
Since:
2.1.0
Procedure: 'implicitExceptionHandler'

This procedure encompasses the usage of other cleanup procedures in this package and is the recommended operation to perform after an exception occurs and is implicitly caught.

Calling this procedure should be the first step in the cleanup sequence of any Test node with the "Implicitly catch exceptions" attribute set.

Parameters:
client - The name of the SUT client.
maxDialogs - Maximum number of modal dialogs that are tried to be closed. (Optional, default 5)
Author:
QFS
Since:
2.1.0
Package: 'combobox'

Procedures to handle Comboboxes. (Swing component javax.swing.JComboBox)

Author:
QFS
Since:
2.1.0
Procedure/DependencyDescription
ProceduregetItemCount
Return the number of items of a given combo-box.
ProceduresetValue
Select specified value of a given combobox.
ProceduresetValueViaIndex
Set a value in the combobox.
ProceduresetValueViaSUTScript
Select specified value of a given combobox using a SUT script.
Procedure: 'getItemCount'

Return the number of items of a given combo-box. It uses the method getModel().getSize() to get the number.

Parameters:
id - The component-ID of the combo-box.
Returns:
itemCount
Author:
QFS
Since:
3.0
Procedure: 'setValue'

Select specified value of a given combobox.

If the given value is empty, no action will take place.

Parameters:
client - The name of the SUT client.
id - ID of the button to open the list.
listId - ID of the list containing values.
value - Value, which should be selected.
separator - Separator to use for the list syntax. Default is @ for text values, also available & for index and % for regexp.
Author:
QFS
Since:
2.1.0
Procedure: 'setValueViaIndex'

Set a value in the combobox.

Parameters:
client - The name of the SUT client.
id - ID of the button to open the list.
value - The value to be set.
separator - Separator to use for the list syntax. Default is @ for text values, also available & for index and % for regexp.
Author:
QFS
Since:
3.1.2
Procedure: 'setValueViaSUTScript'

Select specified value of a given combobox using a SUT script. It uses the API-method setSelectedItem() of javax.swing.JCombobox

If the given value is empty, no action will take place.

Parameters:
client - The name of the SUT client.
id - ID of the button to open the list.
value - Value, which should be selected.
separator - Separator to use for the list syntax. Default is @ for text values, also available & for index and % for regexp.
Author:
QFS
Since:
2.1.0
Package: 'filechooser'

Procedures for accessing file chooser dialogs. (Swing component javax.swing.JFileChooser)

Author:
QFS
Since:
1.05.0
Procedure/DependencyDescription
ProceduredisableNameResolver
Uninstall the JFileChooser name resolver.
ProcedureenableNameResolver
Install the JFileChooser name resolver.
ProcedureselectFile
Select a file in a JFileChooser dialog.
Procedure: 'disableNameResolver'

Uninstall the JFileChooser name resolver.

Parameters:
client - The name of the SUT client.
Author:
QFS
Since:
1.05.0
Procedure: 'enableNameResolver'

Install the JFileChooser name resolver. The effect is similar to assigning names to the most important components in JFileChooser dialogs with setName().

Parameters:
client - The name of the SUT client.
Author:
QFS
Since:
1.05.0
Procedure: 'selectFile'

Select a file in a JFileChooser dialog.

The filechooser dialog must already be open (or at least be triggered to open).

Parameters:
client - The name of the SUT client.
file - The file to select (relative or absolute to the filechooser's current directory).
Author:
QFS
Since:
1.05.0
Package: 'general'

Procedures, which work for any Swing component.

Author:
QFS
Since:
2.1.0
Procedure/DependencyDescription
ProcedureclickAtComponent
Click on a given component, but only if the according parameter is set to true.
ProceduredeleteOverrideComponent
Delete the current association of PriorityAwtSwingComponent.
ProceduredoClick
Click on a given component.
ProceduresetLocation
Set the location of a given component.
ProceduresetOverrideComponent
Set a given component to the PriorityAwtSwingComponent.
ProceduresetSize
Set the wdith and the height of a given component.
Procedure: 'clickAtComponent'

Click on a given component, but only if the according parameter is set to true.

Parameters:
client - The name of the SUT client.
id - The Id of the target-component.
click - If this is set to true, the click will be performed, otherwise nothing happens.
Author:
QFS
Since:
3.0
Procedure: 'deleteOverrideComponent'

Delete the current association of PriorityAwtSwingComponent.

Parameters:
client - The name of the SUT client.
Author:
QFS
Since:
3.3.0
Procedure: 'doClick'

Click on a given component.

Parameters:
client - The name of the SUT client.
id - The Id of the target-component.
Author:
QFS
Since:
2.1.0
Procedure: 'setLocation'

Set the location of a given component.

It uses setLocation(x,y) to set the location.

Parameters:
client - The name of the SUT client.
id - The Id of the target-component.
x - The new x-coordinate of the location.
y - The new y-coordinate of the location.
Author:
QFS
Since:
2.1.0
Procedure: 'setOverrideComponent'

Set a given component to the PriorityAwtSwingComponent.

Parameters:
client - The name of the SUT client.
id - The Id of the target-component.
Author:
QFS
Since:
3.3.0
Procedure: 'setSize'

Set the wdith and the height of a given component.

It uses setSize(width, height) to set the size.

Parameters:
client - The name of the SUT client.
id - The Id of the target-component.
width - The new width of the component.
height - The new height of the component.
Author:
QFS
Since:
2.1.0
Package: 'list'

Procedures for accessing lists. (Swing component javax.swing.JList)

Author:
QFS
Since:
3.0
Procedure/DependencyDescription
ProceduregetIndexOfItem
Return the current index of a given item.
ProceduregetItemCount
Return the number of items of a given list.
ProceduregetValueOfItem
Return the text of a given item.
ProcedureselectItem
Select a given item by a mouse-click on it.
Procedure: 'getIndexOfItem'

Return the current index of a given item.

Sample usage: Can be used to determine the numeric index of an item like 'Price'.

Parameters:
id - ID of the list.
item - The item.
itemSeparator - Separator to use for the item syntax. Default is @ for text values, also available & for index and % for regexp.
Returns:
index The current index of the item, which has been read by the 'Fetch Index' node of QF-Test.
Author:
QFS
Since:
3.1.1
Procedure: 'getItemCount'

Return the number of items of a given list. It uses the method getModel().getSize() to get the number.

Parameters:
id - The component-ID of the list.
Returns:
itemCount
Author:
QFS
Since:
3.0
Procedure: 'getValueOfItem'

Return the text of a given item.

Sample usage: Determine the text of the second item.

Parameters:
id - ID of the list.
item - The item.
itemSeparator - Separator to use for the item syntax. Default is @ for text values, also available & for index and % for regexp.
Returns:
value The value of the item.
Author:
QFS
Since:
3.1.1
Procedure: 'selectItem'

Select a given item by a mouse-click on it.

Parameters:
id - ID of the list.
item - The item.
itemSeparator - Separator to use for the item syntax. Default is @ for text values, also available & for index and % for regexp.
Author:
QFS
Since:
3.1.1
Package: 'checks'

Procedures for checking a list.

Author:
QFS
Since:
3.1.1
Procedure/DependencyDescription
ProcedurecheckNumberOfItems
Check the number of items of a given list according to a specified comparison mode.
Procedure: 'checkNumberOfItems'

Check the number of items of a given list according to a specified comparison mode.

It uses JList.getModel().getSize() to get the number. Sample usage: You can check, that a list has exactly 6 items or that the table has less then 10 items.

Parameters:
id - The id of the list.
compareValue - The comparison value.
compareMode - The comparison mode =, if the compareValue should be equal than the actual amount of items. <, if the compareValue should be greater than the actual amount of items. >, if the compareValue should be less than the actual amount of items. <=, if the compareValue should be greater or equal than the actual amount of items. >=, if the compareValue should be less or equal the actual amount of items.
errorLevel - The kind of error, which should be logged. Either EXCEPTION, ERROR, WARNING or MESSAGE.
appearInReport - Flag, whether to show check in report, if a message or warning are set as errorLevel. If this is set to 1, the check will be shown in the report.
Exceptions:
UserException, - if wrong comparison mode has been set.
Author:
QFS
Since:
3.1.1
Package: 'selection'

Procedures to (de-)select certain items of a list.

Author:
QFS
Since:
3.1.1
Procedure/DependencyDescription
ProceduredeselectAllItems
Deselect all items.
ProceduredeselectItem
Deselect a given item, specified by its index.
ProceduredeselectItemRange
Deselect a range of items, specified by their index.
ProcedureselectAllItems
Select all items.
ProcedureselectItem
Select a given item, specified by its index.
ProcedureselectItemRange
Select a range of items, specified by their index.
Procedure: 'deselectAllItems'

Deselect all items. It uses removeSelectionInterval.

Parameters:
id - ID of the list.
Author:
QFS
Since:
3.1.1
Procedure: 'deselectItem'

Deselect a given item, specified by its index. It uses removeSelectionInterval.

Parameters:
id - ID of the list.
item - The index of the item.
Author:
QFS
Since:
3.1.1
Procedure: 'deselectItemRange'

Deselect a range of items, specified by their index. It uses removeSelectionInterval.

Parameters:
id - ID of the list.
startItem - The index of first item to be selected.
endItem - The index of last item to be selected.
Author:
QFS
Since:
3.1.1
Procedure: 'selectAllItems'

Select all items. It uses setSelectionInterval.

Parameters:
id - ID of the list.
Author:
QFS
Since:
3.1.1
Procedure: 'selectItem'

Select a given item, specified by its index. It uses setSelectionInterval.

Parameters:
id - ID of the list.
row - The index of the item.
Author:
QFS
Since:
3.1.1
Procedure: 'selectItemRange'

Select a range of items, specified by their index. It uses setSelectionInterval.

Parameters:
id - ID of the list.
startItem - The index of first item to be selected.
endItem - The index of last item to be selected.
Author:
QFS
Since:
3.1.1
Package: 'menu'

Procedures to select menu items and checkbox menu items. (Swing components javax.swing.JMenuItem and javax.swing.JCheckBoxMenuItem from javax.swing.JMenu)

Author:
QFS
Since:
1.05.0
Procedure/DependencyDescription
ProcedureselectItem
Select an item from a menu.
ProcedureselectSubItem
Select an item within a submenu.
ProceduresetCheckItem
Select a checkbox menu item.
ProceduresetSubCheckItem
Select a checkbox menu item within within a submenu.
Procedure: 'selectItem'

Select an item from a menu.

For example: for the File -> Open action, the component ID of "File" is the menu, and the ID for "Open" is the item.

Parameters:
client - The name of the SUT client.
menu - The id of the menu.
item - The id of menu item.
Author:
QFS
Since:
1.05.0
Procedure: 'selectSubItem'

Select an item within a submenu.

For example: for the View -> Terminal -> Show action, the component ID of "View" is the menu, the ID for "Terminal" is the item, and the ID for "Show" is the sub-item to select.

Parameters:
client - The name of the SUT client.
menu - The id of the menu.
item - The id of the item to open the submenu.
subItem - The id of item in submenu.
Author:
QFS
Since:
1.05.0
Procedure: 'setCheckItem'

Select a checkbox menu item.

For example: for the View -> Show Details action, the component ID of "View" is the menu, and the ID for "Show Details" is the checbox item to set (to true or false).

Parameters:
client - The name of the SUT client.
menu - The id of the menu.
checkItem - The id of the checkbox item.
checkItemValue - The check item value to be set - 'true' to select the checkbox item (default), 'false' to deselect.
Author:
QFS
Since:
1.05.0
Procedure: 'setSubCheckItem'

Select a checkbox menu item within within a submenu.

For example: for the View -> Terminal -> Wrap Lines action, the component ID of "View" is the menu, the ID for "Terminal" is the item and the ID for "Wrap Lines" is the checkbox menu item to set (to true or false).

Parameters:
client - The name of the SUT client.
menu - The id of the menu.
item - The id of the item to open the submenu.
subCheckItem - The id of the checkbox item in the submenu.
checkItemValue - The checkbox item value to be set - "true" to select the checkbox item (default), "false" to deselect.
Author:
QFS
Since:
1.05.0
Package: 'optionpane'

Procedures for accessing standard error/message dialogs. (Swing component javax.swing.JOptionPane)

Author:
QFS
Since:
1.07.0
Procedure/DependencyDescription
ProceduredisableNameResolver
Uninstall the JOptionPane name resolver.
ProcedureenableNameResolver
Install the JOptionPane name resolver.
Procedure: 'disableNameResolver'

Uninstall the JOptionPane name resolver.

Parameters:
client - The name of the SUT client.
Author:
QFS
Since:
1.07.0
Procedure: 'enableNameResolver'

Install the JOptionPane name resolver. The effect is similar to assigning names to the most important components in JOptionPane dialogs with setName().

Parameters:
client - The name of the SUT client.
Author:
QFS
Since:
1.07.0
Package: 'popupmenu'

Procedures to select items and checkbox menu items from popup menus.

Note that for all procedures, the popup menu must first be opened by the calling test-suite, as the popup menu is component-dependent.

See package "menu" for more details about menus and sub-menus. (Swing components javax.swing.JMenuItem and javax.swing.JCheckBoxMenuItem from javax.swing.JPopupMenu)

Author:
QFS
Since:
1.05.0
Procedure/DependencyDescription
ProcedureselectItem
Select an item in a popup menu.
ProcedureselectSubItem
Select an item within a submenu of a popup menu.
ProceduresetCheckItem
Select a checkbox menu item in a popup menu.
ProceduresetSubCheckItem
Select a checkbox menu item within a submenu of a popup menu.
Procedure: 'selectItem'

Select an item in a popup menu.

Parameters:
client - The name of the SUT client.
item - The id of menu item.
Author:
QFS
Since:
1.05.0
Procedure: 'selectSubItem'

Select an item within a submenu of a popup menu.

Parameters:
client - The name of the SUT client.
item - The id of the item to open the submenu.
subItem - The id of item in submenu.
Author:
QFS
Since:
1.05.0
Procedure: 'setCheckItem'

Select a checkbox menu item in a popup menu.

Parameters:
client - The name of the SUT client.
checkItem - The id of the menu checkbox item.
checkItemValue - The checkbox item value to be set - "true" to select the checkbox item (default), "false" to deselect.
Author:
QFS
Since:
1.05.0
Procedure: 'setSubCheckItem'

Select a checkbox menu item within a submenu of a popup menu.

Parameters:
client - The name of the SUT client.
item - The id of item to open the submenu.
subCheckItem - The id of the checkbox item in the submenu.
checkItemValue - The checkbox item value to be set - "true" to select the checkbox item (default), "false" to deselect.
Author:
QFS
Since:
1.05.0
Package: 'slider'

Procedures to access sliders. (Swing component javax.swing.JSlider)

Author:
QFS, mm
Since:
3.4.1
Procedure/DependencyDescription
ProceduregetValue
Return the value of a slider component.
ProceduresetValue
Set the value of a slider component.
Procedure: 'getValue'

Return the value of a slider component.

Parameters:
id - The component ID of the slider.
Returns:
The current vale of the slider.
Author:
QFS, mm
Since:
3.4.1
Procedure: 'setValue'

Set the value of a slider component.

Parameters:
id - The component ID of the slider.
value - The value to set.
Author:
QFS, mm
Since:
3.4.1
Package: 'checks'

Procedure for checking slider values.

Author:
QFS, mm
Since:
3.4.1
Procedure/DependencyDescription
ProcedurecheckValue
Check the value of a slider component
Procedure: 'checkValue'

Check the value of a slider component

Parameters:
id - The component ID of the slider.
value - The value to be checked,
regexp - if this value is set to true, the text will be checks as regular-expression.
negate - if, the check should check for anything but the given text.
nameCheckType - the value for "name of check-type" attribute.
throwExc - whether the check should throw an exception on failure.
reportName - the Name for the check in the report.
Author:
QFS, mm
Since:
3.4.1
Package: 'startup'
Procedure/DependencyDescription
ProceduresetDelays
Set delays for the QF-Test SUT initialization process.
Procedure: 'setDelays'

Set delays for the QF-Test SUT initialization process.

The Java WebStart launcher has several race conditions where initialization of QF-Test SUT client wrapper can lead to problems, even to crashes. By calling this procedure before SUT startup with one or more of the following parameters it is possible to delay QF-Tests's SUT initialization at critical points. Unfortunately there is no single optimal setting. In case you experience problems with SUT startup you will need to experiment with these values. Start with few parameters and values between 5000 and 10000.

Parameters:
delay-1 - Earliest place, called once. Good choice up to 30000.
delay0 - Before checking ThreadGroups. Called often, use small values.
delay10 - After checking ThreadGroups. Called often, use small values.
delay1 - Before checking ThreadGroups for security engine. Called often, use small values.
delay11 - After checking ThreadGroups for security engine. Called often, use small values.
delay2 - Applet plugin only, good choice for that.
delay3 - Before initializing RMI, normal engine. Good choice.
delay13 - Before initializing RMI, security engine. Good choice.
delay4 - Before creating security engine. Rarely useful.
delay5 - Before installing EventQueue. Rarely useful.
delay6 - After installing EventQueue. Rarely useful.
delay7 - Before connecting with QF-Test. Rarely useful.
Author:
QFS,gs
Since:
3.5
Package: 'tabbedpane'

Procedure to work with TabbedPanes. (Swing component javax.swing.JTabbedPane or any other TabFolder implementations)

Author:
QFS
Since:
2.1.0
Procedure/DependencyDescription
ProcedurecloseTab
Close a tab via clicking on the "X "button.
ProcedureselectTab
Select a tab in a given TabbedPane.
Procedure: 'closeTab'

Close a tab via clicking on the "X "button. The procedure assumes that the "X" button is located 10 pixel away from the right corner. If this doesn't work for you, you can configure this via the parameter "wdiff".

Parameters:
id - ID of tab, which should be closed.
wdiff - X position of the "x" button seen from the right side.
Author:
QFS
Since:
2.1.0
Procedure: 'selectTab'

Select a tab in a given TabbedPane.

Parameters:
client - The name of the SUT client.
id - The component-if of the tabbedpane to select.
separator - Separator to use for the tab syntax. Default is @ for text values, also available & for index and % for regexp.
value - The value to select.
Author:
QFS
Since:
2.1.0
Package: 'table'

Procedures to access tables. (Swing component javax.swing.JTable)

Author:
QFS
Since:
1.08.4
Procedure/DependencyDescription
ProceduregetColumnCount
Return the number of columns of a given table.
ProceduregetIndexOfColumn
Return the current index of a given column.
ProceduregetNameOfColumn
Return the header text of a given column.
ProceduregetRowCount
Return the number of rows of a given table.
ProceduregetRowIndexOfCell
Return the row number of a given cell.
ProceduregetValueOfCell
Return the text of a given cell.
ProcedureresizeColumn
Rezise width of a table column.
ProcedureselectCell
Select a given cell.
Procedure: 'getColumnCount'

Return the number of columns of a given table. It uses the method getColumnCount() to get the number.

Parameters:
id - The component-ID of the table.
Returns:
columnCount
Author:
QFS
Since:
2.1.0
Procedure: 'getIndexOfColumn'

Return the current index of a given column.

Sample usage: Can be used to determine the numeric index of a column like 'Price'.

Parameters:
id - ID of the table.
column - The column.
columnSeparator - Separator to use for the column syntax. Default is @ for text values, also available & for index and % for regexp.
Returns:
index The current index of the column, which has been read by the 'Fetch Index' node of QF-Test.
Author:
QFS
Since:
3.1.1
Procedure: 'getNameOfColumn'

Return the header text of a given column.

Sample usage: Determine the title of the second colum.

Parameters:
id - ID of the table.
column - The column.
columnSeparator - Separator to use for the column syntax. Default is @ for text values, also available & for index and % for regexp.
Returns:
name The name of the column.
Author:
QFS
Since:
3.1.1
Procedure: 'getRowCount'

Return the number of rows of a given table. It uses the method JTable.getRowCount() to get the number.

Parameters:
id - The component-id of the table.
Returns:
rowCount
Author:
QFS
Since:
2.1.0
Procedure: 'getRowIndexOfCell'

Return the row number of a given cell.

Sample usage: Can be used to determine, in which row a dedicated cell is located.

Parameters:
id - ID of the table.
column - The column.
row - The row.
columnSeparator - Separator to use for the column syntax. Default is @ for text values, also available & for index and % for regexp.
rowSeparator - Separator to use for the row syntax. Default is @ for text values, also available & for index and % for regexp.
Returns:
index The current index of the row, which has been read by the 'Fetch Index' node of QF-Test.
Author:
QFS
Since:
3.1.1
Procedure: 'getValueOfCell'

Return the text of a given cell.

Sample usage: Can be used to determine the text of the cell in the first column and first row.

Parameters:
id - ID of the table.
column - The column.
row - The row.
columnSeparator - Separator to use for the column syntax. Default is @ for text values, also available & for index and % for regexp.
rowSeparator - Separator to use for the row syntax. Default is @ for text values, also available & for index and % for regexp.
Returns:
value The current value of the row, which has been read by the 'Fetch text' node of QF-Test.
Author:
QFS
Since:
3.1.1
Procedure: 'resizeColumn'

Rezise width of a table column.

Parameters:
client - The name of the client.
idColumn - The id of the table column to be resized.
width - The new width - additional or absolute, dependent on the 'absolute' parameter. For additional width also negative values are possible to shrink the column size.
absolute - True, if the with value shall be the absolute new column width (default is 'true').
Author:
QFS
Since:
1.08.4
Procedure: 'selectCell'

Select a given cell.

Parameters:
id - ID of the table.
column - The column.
row - The row.
columnSeparator - Separator to use for the column syntax. Default is @ for text values, also available & for index and % for regexp.
rowSeparator - Separator to use for the row syntax. Default is @ for text values, also available & for index and % for regexp.
Author:
QFS
Since:
2.1.0
Package: 'checkbox'

Procedures to set the state of checkboxes in a table-cell. These procedures become necessary, because checkboxes in tables cannot be treated like normale checkboxes.

Author:
QFS
Since:
3.0
Procedure/DependencyDescription
Proceduredeselect
Deselect a checkbox in a table-cell .If the checkbox is already de-selected, no action is performed.
Procedureselect
Select a checkbox in a table-cell.
Procedureset
Set checkbox in a table-cell to the given state.
Procedure: 'deselect'

Deselect a checkbox in a table-cell .If the checkbox is already de-selected, no action is performed.

Parameters:
client - The name of the SUT client.
id - The id of the checkbox, including the table-id and the addressing of the cell.
Author:
QFS
Since:
3.0
Procedure: 'select'

Select a checkbox in a table-cell. If the checkbox is already selected, no action is performed.

Parameters:
client - The name of the SUT client.
id - The id of the checkbox, including the table-id and the addressing of the cell.
Author:
QFS
Since:
3.0
Procedure: 'set'

Set checkbox in a table-cell to the given state.

Parameters:
client - The name of the SUT client.
id - The id of the checkbox, including the table-id and the addressing of the cell.
check - The check value to be set (either true or false).
Author:
QFS
Since:
3.0
Package: 'checks'

Procedures for checking a table.

Author:
QFS
Since:
3.1.1
Procedure/DependencyDescription
ProcedurecheckNumberOfRows
Check the number of rows of a given table according to a specified comparison mode.
Procedure: 'checkNumberOfRows'

Check the number of rows of a given table according to a specified comparison mode. It uses the method JTable.getRowCount() to get the number.

Sample usage: You can check, that a table has exactly 6 rows or that the table has less then 10 rows.

Parameters:
id - The id of the table.
compareValue - The comparison value.
compareMode - The comparison mode =, if the compareValue should be equal than the actual amount of rows. <, if the compareValue should be greater than the actual amount of rows. >, if the compareValue should be less than the actual amount of rows. <=, if the compareValue should be greater or equal than the actual amount of rows. >=, if the compareValue should be less or equal the actual amount of rows.
errorLevel - The kind of error, which should be logged. Either EXCEPTION, ERROR, WARNING or MESSAGE.
appearInReport - Flag, whether to show check in report, if a message or warning are set as errorLevel. If this is set to 1, the check will be shown in the report.
Exceptions:
UserException, - if wrong comparison mode has been set.
Author:
QFS
Since:
3.1.1
Package: 'selection'

Procedures to (de-)select certain rows of a table.

Author:
QFS
Since:
2.1.0
Procedure/DependencyDescription
ProceduredeselectAllRows
Deselect all rows.
ProceduredeselectRow
Deselect a given row, specified by its index.
ProceduredeselectRowRange
Deselect a range of rows, specified by their index.
ProcedureselectAllRows
Select all rows.
ProcedureselectRow
Select a given row, specified by its index.
ProcedureselectRowRange
Select a range of rows, specified by their index.
Procedure: 'deselectAllRows'

Deselect all rows. It uses removeSelectionInterval.

Parameters:
id - ID of the table.
Author:
QFS
Since:
2.1.0
Procedure: 'deselectRow'

Deselect a given row, specified by its index. It uses removeSelectionInterval.

Parameters:
id - ID of the table.
row - The index of the row.
Author:
QFS
Since:
2.1.0
Procedure: 'deselectRowRange'

Deselect a range of rows, specified by their index. It uses removeSelectionInterval.

Parameters:
id - ID of the table.
startRow - The index of first row to be selected.
endRow - The index of last row to be selected.
Author:
QFS
Since:
2.1.0
Procedure: 'selectAllRows'

Select all rows. It uses setSelectionInterval.

Parameters:
id - ID of the table.
Author:
QFS
Since:
2.1.0
Procedure: 'selectRow'

Select a given row, specified by its index. It uses setSelectionInterval.

Parameters:
id - ID of the table.
row - The index of the row.
Author:
QFS
Since:
2.1.0
Procedure: 'selectRowRange'

Select a range of rows, specified by their index. It uses setSelectionInterval.

Parameters:
id - ID of the table.
startRow - The index of first row to be selected.
endRow - The index of last row to be selected.
Author:
QFS
Since:
2.1.0
Package: 'text'

Procedures to access text fields and text areas. (Swing components javax.swing.JTextField and javax.swing.JTextArea)

Author:
QFS
Since:
1.05.0
Procedure/DependencyDescription
ProcedureclearArea
Clear a multi-line text area.
ProcedureclearField
Clear a simple text field.
ProceduresetText
Set a given text to a given text-field or text-area.
ProceduresetTextFromFile
Read the content of a given file and set its content to a given text-field.
Procedure: 'clearArea'

Clear a multi-line text area.

Parameters:
client - The name of the SUT client.
id - The id of the text area.
Author:
QFS
Since:
1.05.0
Procedure: 'clearField'

Clear a simple text field.

Parameters:
client - The name of the SUT client.
id - The id of the text field.
Author:
QFS
Since:
1.05.0
Procedure: 'setText'

Set a given text to a given text-field or text-area.

If the text is empty, no action will take place.

Parameters:
id - ID of the textfield.
text - Text to be set.
append - If this value is set to true, the text will be appended to the current values.
clear - If this value is set to true, the text-field will be cleared in case an empty string is given as parameter "text".
replaySingleEvents - If this value is set to true, the text will be inserted replaying single events.
newline - the separator sign for marking a linebreak within the text
Author:
QFS
Since:
2.1.0
Procedure: 'setTextFromFile'

Read the content of a given file and set its content to a given text-field.

Parameters:
id - The id of the text-field to set.
file - The path to the file.
Author:
QFS
Since:
3.1.1
Package: 'tree'

Procedures to access trees. (Swing component javax.swing.JTree)

Author:
QFS
Since:
1.05.0
Procedure/DependencyDescription
ProcedurecallbackPrintNodeText
Example for a callback procedure used by expandNodes.
Procedurecollapse
Collapse a tree node.
ProcedurecollapseNode
Collapse a tree node.
Procedureexpand
Expand a tree node.
ProcedureexpandNode
Expand a tree node.
ProcedureexpandNodes
Expand a tree node recursively.
ProceduregetIndexOfNode
Return the current index of a given node.
ProceduregetRowCount
Return the number of rows of a given tree.
ProceduregetValueOfNode
Return the text of a given node.
ProcedureselectNode
Select a given node.
Procedure: 'callbackPrintNodeText'

Example for a callback procedure used by expandNodes.

Parameters:
treeId - The id of the tree.
node - The index of the node.
Author:
QFS
Since:
3.0
Procedure: 'collapse'

Collapse a tree node.

Parameters:
client - The name of the SUT client.
node - The id of the tree node to collapse.
Author:
QFS
Since:
1.05.0
Procedure: 'collapseNode'

Collapse a tree node.

Parameters:
client - The name of the SUT client.
id - The id of the tree.
node - The node, e.g. like '/Root/Price' or '/0/0'.
separator - Separator to use for the node syntax. Default is @ for text values, also available & for index and % for regexp.
Author:
QFS
Since:
3.0
Procedure: 'expand'

Expand a tree node.

Parameters:
client - The name of the SUT client.
node - The id of the tree node to expand.
Author:
QFS
Since:
1.05.0
Procedure: 'expandNode'

Expand a tree node.

Parameters:
client - The name of the SUT client.
id - The id of the tree.
node - The node, e.g. '/Root/Price' or '/0/0'.
separator - Separator to use for the node syntax. Default is @ for text values, also available & for index and % for regexp.
Author:
QFS
Since:
3.0
Procedure: 'expandNodes'

Expand a tree node recursively.

Parameters:
id - The id of the tree node.
callbackProc - The name of a procedure to be called for every visited node.
Author:
QFS
Since:
3.0
Procedure: 'getIndexOfNode'

Return the current index of a given node.

Sample usage: Can be used to determine the numeric index of a node like '/Root/Price'.

Parameters:
id - ID of the tree.
node - The node. like '/Root/Price' or '/0/0'.
nodeSeparator - Separator to use for the node syntax. Default is @ for text values, also available & for index and % for regexp.
Returns:
index The current index of the node, which has been read by the 'Fetch Index' node of QF-Test.
Author:
QFS
Since:
3.1.1
Procedure: 'getRowCount'

Return the number of rows of a given tree. It uses the method getRowCount() to get the number.

Parameters:
id - The component-id of the tree.
Returns:
rowCount
Author:
QFS
Since:
3.1.1
Procedure: 'getValueOfNode'

Return the text of a given node.

Sample usage: Determine the text value for a node referenced by index like /0/1.

Parameters:
id - ID of the tree.
node - The node. It should be something like '/Root/Price' or '/0/0'.
nodeSeparator - Separator to use for the node syntax. Default is @ for text values, also available & for index and % for regexp.
Returns:
name The value of the node.
Author:
QFS
Since:
3.1.1
Procedure: 'selectNode'

Select a given node.

Parameters:
id - ID of the tree.
node - The node, e.g. '/Root/Price' or '/0/0'.
separator - Separator to use for the node syntax. Default is @ for text values, also available & for index and % for regexp.
Author:
QFS
Since:
2.1.0
Package: 'checks'

Procedures for checking a tree.

Author:
QFS
Since:
3.1.1
Procedure/DependencyDescription
ProcedurecheckNumberOfRows
Check the number of visilble rows of a given tree according to a specified comparison mode.
Procedure: 'checkNumberOfRows'

Check the number of visilble rows of a given tree according to a specified comparison mode. It uses JTree.getRowCount to determine the current number of rows.

Sample usage: You can check, that a tree has exactly 6 visible rows or that the tree has less then 10 visible rows.

Parameters:
id - The id of the tree.
compareValue - The comparison value.
compareMode - The comparison mode =, if the compareValue should be equal than the actual amount of rows. <, if the compareValue should be greater than the actual amount of rows. >, if the compareValue should be less than the actual amount of rows. <=, if the compareValue should be greater or equal than the actual amount of rows. >=, if the compareValue should be less or equal the actual amount of rows.
errorLevel - The kind of error, which should be logged. Either EXCEPTION, ERROR, WARNING or MESSAGE.
appearInReport - Flag, whether to show check in report, if a message or warning are set as errorLevel. If this is set to 1, the check will be shown in the report.
Exceptions:
UserException, - if wrong comparison mode has been set.
Author:
QFS
Since:
3.1.1
Package: 'swt'

Procedures for advanced manipulation of SWT components.

Author:
QFS
Since:
2.0.3
Package: 'checkbox'

Procedures to set the state of checkboxes. (SWT component org.eclipse.swt.widgets.Button)

Author:
QFS
Since:
2.1.0
Procedure/DependencyDescription
Proceduredeselect
Deselect a checkbox .If the checkbox is already de-selected, no action is performed.
Procedureselect
Select a checkbox.
Procedureset
Set checkbox to the given state.
Procedure: 'deselect'

Deselect a checkbox .If the checkbox is already de-selected, no action is performed.

Parameters:
client - The name of the SUT client.
id - The id of the check-box.
Author:
QFS
Since:
2.1.0
Procedure: 'select'

Select a checkbox. If the checkbox is already selected, no action is performed.

Parameters:
client - The name of the SUT client.
id - The id of the check-box.
Author:
QFS
Since:
2.1.0
Procedure: 'set'

Set checkbox to the given state.

Parameters:
client - The name of the SUT client.
id - The id of the checkbox.
check - The check value to be set (either true or false).
Author:
QFS
Since:
2.1.0
Package: 'cleanup'

The procedures in this package are useful for generic cleanup after an exception is thrown. In some cases a menu or modal dialog may have been left open, causing future events for the SUT to be blocked.

Author:
QFS
Since:
2.1.0
Procedure/DependencyDescription
ProcedurecloseAllDialogsAndModalShells
Close all modal dialogs.
ProcedurecloseAllMenus
Close all menus unconditionally.
ProcedureimplicitExceptionHandler
This procedure encompasses the usage of other cleanup procedures in this package and is the recommended operation to perform after an exception occurs and is implicitly caught.
Procedure: 'closeAllDialogsAndModalShells'

Close all modal dialogs. A modal dialog that is left open will cause events for the SUT to be blocked. Ensuring that modal dialogs are closed is a good operation to conduct in a setup/cleanup sequence. Closing all instances of org.eclipse.swt.widgets.Dialog and all modal instances of org.eclipse.swt.widgets.Shell.

Parameters:
client - The name of the SUT client.
maxDialogs - Maximum number of modal dialogs that are tried to be closed. (Optional, default 5)
Author:
QFS
Since:
2.1.0
Procedure: 'closeAllMenus'

Close all menus unconditionally. A menu left open (or even just selected) will cause events for the SUT to be blocked. This procedure is recommened for cleanup after an exception occurs.

Parameters:
client - The name of the SUT client.
Author:
QFS
Since:
2.1.0
Procedure: 'implicitExceptionHandler'

This procedure encompasses the usage of other cleanup procedures in this package and is the recommended operation to perform after an exception occurs and is implicitly caught.

Calling this procedure should be the first step in the cleanup sequence of any Test node with the "Implicitly catch exceptions" attribute set.

Parameters:
client - The name of the SUT client.
maxDialogs - Maximum number of modal dialogs that are tried to be closed. (Optional, default 5)
Author:
QFS
Since:
2.1.0
Package: 'colordialog'

Procedures to handle Colordialogs. (SWT component org.eclipse.swt.widgets.ColorDialog)

Author:
QFS
Since:
3.0
Procedure/DependencyDescription
ProcedureselectColor
Select a specified color of a ColorDialog.
Procedure: 'selectColor'

Select a specified color of a ColorDialog.

The color should be in RGB values, e.g. #FF0000 for red. If no color is specified, it will close the dialog without selection.

Parameters:
client - The name of the SUT client.
id - ID of the ColorDialog.
color - Color to be selected.
Author:
QFS
Since:
3.0
Package: 'combo'

Procedures to handle Comboboxes. (SWT component org.eclipse.swt.widgets.Combo)

Author:
QFS
Since:
2.1.0
Procedure/DependencyDescription
ProceduregetItemCount
Return the number of items of a given combo-box.
ProceduresetValue
Select specified value of a given combobox using a selection event.
ProceduresetValueViaSUTScript
Select specified value of a given combobox using a SUT script.
Procedure: 'getItemCount'

Return the number of items of a given combo-box. It uses the method getItemCount() to get the number.

Parameters:
id - The component-ID of the combo-box.
Returns:
itemCount
Author:
QFS
Since:
3.0
Procedure: 'setValue'

Select specified value of a given combobox using a selection event.

If the given value is empty, no action will take place.

Parameters:
client - The name of the SUT client.
id - ID of the Combo.
value - Value, which should be selected.
separator - Separator to use for the list syntax. Default is @ for text values, also available & for index and % for regexp.
Author:
QFS
Since:
2.1.0
Procedure: 'setValueViaSUTScript'

Select specified value of a given combobox using a SUT script. It used the API-method select().

If the given value is empty, no action will take place.

Parameters:
client - The name of the SUT client.
id - ID of the Combo.
value - Value, which should be selected.
Author:
QFS
Since:
2.1.0
Package: 'ctabfolder'

Procedures for SWT CTabFolder widgets. (SWT component org.eclipse.swt.custom.CTabFolder)

Author:
QFS,mm
Since:
2.0.3
Procedure/DependencyDescription
ProcedurecheckTabIsDirty
This procedure raises an error, if a given tab is not dirty.
ProcedurecloseTab
Close a tab in a generic CTabFolder that is identified only by the fact that it contains the desired tab.
ProcedureopenViewMenu
Open the View Menu for a generic CTabFolder that is identified only by the fact that it contains the desired tab.
ProcedureselectTab
Select a tab in a generic CTabFolder that is identified only by the fact that it contains the desired tab.
Procedure: 'checkTabIsDirty'

This procedure raises an error, if a given tab is not dirty. This procedure checks for the standard dirty marker, i.e. a * at the beginning of the tab name.

Parameters:
client - The name of the SUT client.
tabname - The name of the tab to select.
separator - @ for addressing the tab name by text, % for addressing the tab by regular expression. Note: & is not supported by this procedure.
expectedDirty - True, if marker is expected. False if marker is not expected.
throwExc - Whether the check should throw an exception on failure.
reportName - The Name for the check in the report.
Author:
QFS,mm
Since:
3.4.2
Procedure: 'closeTab'

Close a tab in a generic CTabFolder that is identified only by the fact that it contains the desired tab. Even the target window is arbitrary.

Parameters:
client - The name of the SUT client.
tabname - The name of the tab to close.
separator - @ for addressing the tab name by text, % for addressing the tab by regular expression. Note: & is not supported by this procedure.
Author:
QFS,mm
Since:
2.0.3
Procedure: 'openViewMenu'

Open the View Menu for a generic CTabFolder that is identified only by the fact that it contains the desired tab. Even the target window is arbitrary.

Parameters:
client - The name of the SUT client.
tabname - The name of the tab to which the View Menu belongs.
Author:
QFS,gs
Since:
3.4.7
Procedure: 'selectTab'

Select a tab in a generic CTabFolder that is identified only by the fact that it contains the desired tab. Even the target window is arbitrary.

Parameters:
client - The name of the SUT client.
tabname - The name of the tab to select.
separator - @ for addressing the tab name by text, % for addressing the tab by regular expression. Note: & is not supported by this procedure.
Author:
QFS,mm
Since:
2.0.3
Package: 'directorydialog'

Procedures for accessing directory dialogs. (SWT component org.eclipse.swt.widgets.DirectoryDialog)

Author:
QFS
Since:
2.1.0
Procedure/DependencyDescription
ProcedureselectDirectory
Select a directory in a DirectoryDialog dialog.
Procedure: 'selectDirectory'

Select a directory in a DirectoryDialog dialog.

The Directorydialog must already be open (or at least be triggered to open).

Parameters:
client - The name of the SUT client.
directory - The directory to select (relative or absolute to the directorydialog's current directory).
Author:
QFS
Since:
2.1.0
Package: 'filedialog'

Procedures for accessing file dialogs. (SWT component org.eclipse.swt.widgets.FileDialog)

Author:
QFS
Since:
2.1.0
Procedure/DependencyDescription
ProcedureselectFile
Select a file in a FileDialog dialog.
Procedure: 'selectFile'

Select a file in a FileDialog dialog.

The filechooser dialog must already be open (or at least be triggered to open).

Parameters:
client - The name of the SUT client.
file - The file to select (relative or absolute to the filechooser's current directory).
Author:
QFS
Since:
2.1.0
Package: 'general'

Procedures, which work for any SWT component.

Author:
QFS
Since:
2.1.0
Procedure/DependencyDescription
ProcedureclickAtComponent
Click on a given component, but only if the according parameter is set to true.
ProceduredeleteOverrideComponent
Delete the current association of PrioritySwtComponent.
ProceduredoClick
Click on a given component.
ProceduresetLocation
Set the location of a given component.
ProceduresetOverrideComponent
Set a given component to the PrioritySwtWidget.
ProceduresetSize
Set the wdith and the height of a given component.
Procedure: 'clickAtComponent'

Click on a given component, but only if the according parameter is set to true.

Parameters:
client - The name of the SUT client.
id - The Id of the target-component.
click - If this is set to true, the click will be performed, otherwise nothing happens.
Author:
QFS
Since:
3.0
Procedure: 'deleteOverrideComponent'

Delete the current association of PrioritySwtComponent.

Parameters:
client - The name of the SUT client.
Author:
QFS
Since:
3.3.0
Procedure: 'doClick'

Click on a given component.

Parameters:
client - The name of the SUT client.
id - The Id of the target-component.
Author:
QFS
Since:
2.1.0
Procedure: 'setLocation'

Set the location of a given component.

It uses setLocation(x,y) to set the location.

Parameters:
client - The name of the SUT client.
id - The Id of the target-component.
x - The new x-coordinate of the location.
y - The new y-coordinate of the location.
Author:
QFS
Since:
2.1.0
Procedure: 'setOverrideComponent'

Set a given component to the PrioritySwtWidget.

Parameters:
client - The name of the SUT client.
id - The Id of the target-component.
Author:
QFS
Since:
3.3.0
Procedure: 'setSize'

Set the wdith and the height of a given component.

It uses setSize(width, height) to set the size.

Parameters:
client - The name of the SUT client.
id - The Id of the target-component.
width - The new width of the component.
height - The new height of the component.
Author:
QFS
Since:
2.1.0
Package: 'instrument'

Procedures for SWT instrumentation.

Author:
QFS
Since:
2.0.3
Procedure/DependencyDescription
Proceduresetup
Instrument an Eclipse/RCP based or standalone SWT application for use with QF-Test.
Procedure: 'setup'

Instrument an Eclipse/RCP based or standalone SWT application for use with QF-Test. Manual chapter 4 describes the effects in detail.

Parameters:
sutdir - The installation directory of the SUT.
plugin - Optional: The specific plugin to instrument. Useful in case the directories are not layed out as expected.
Package: 'list'

Procedures for accessing lists. (SWT component org.eclipse.swt.widgets.List)

Author:
QFS
Since:
3.0
Procedure/DependencyDescription
ProceduregetItemCount
Return the number of items of a given list.
ProceduregetValueOfItem
Return the text of a given item.
ProcedureselectItem
Select a given item by a mouse-click on it.
Procedure: 'getItemCount'

Return the number of items of a given list. It uses the method list.getItemCount() to get the number.

Parameters:
id - The component-ID of the list.
Returns:
itemCount
Author:
QFS
Since:
3.0
Procedure: 'getValueOfItem'

Return the text of a given item.

Sample usage: Determine the text of the second item.

Parameters:
id - ID of the list.
item - The item.
itemSeparator - Separator to use for the item syntax. Default is @ for text values, also available & for index and % for regexp.
Returns:
value The value of the item.
Author:
QFS
Since:
3.1.1
Procedure: 'selectItem'

Select a given item by a mouse-click on it.

Parameters:
id - ID of the list.
item - The item.
itemSeparator - Separator to use for the item syntax. Default is @ for text values, also available & for index and % for regexp.
Author:
QFS
Since:
3.1.1
Package: 'checks'

Procedures for checking a list.

Author:
QFS
Since:
3.1.1
Procedure/DependencyDescription
ProcedurecheckNumberOfItems
Check the number of items of a given list according to a specified comparison mode.
Procedure: 'checkNumberOfItems'

Check the number of items of a given list according to a specified comparison mode.

It uses the method list.getItemCount() to get the number.

Sample usage: You can check, that a list has exactly 6 items or that the table has less then 10 items.

Parameters:
id - The id of the list.
compareValue - The comparison value.
compareMode - The comparison mode =, if the compareValue should be equal than the actual amount of items. <, if the compareValue should be greater than the actual amount of items. >, if the compareValue should be less than the actual amount of items. <=, if the compareValue should be greater or equal than the actual amount of items. >=, if the compareValue should be less or equal the actual amount of items.
errorLevel - The kind of error, which should be logged. Either EXCEPTION, ERROR, WARNING or MESSAGE.
appearInReport - Flag, whether to show check in report, if a message or warning are set as errorLevel. If this is set to 1, the check will be shown in the report.
Exceptions:
UserException, - if wrong comparison mode has been set.
Author:
QFS
Since:
3.1.1
Package: 'selection'

Procedures to (de-)select certain items of a list.

Author:
QFS
Since:
3.1.1
Procedure/DependencyDescription
ProceduredeselectAllItems
Deselect all items.
ProceduredeselectItem
Deselect a given item, specified by its index.
ProceduredeselectItemRange
Deselect a range of items, specified by their index.
ProcedureselectAllItems
Select all items.
ProcedureselectItem
Select a given item, specified by its index.
ProcedureselectItemRange
Select a range of items, specified by their index.
Procedure: 'deselectAllItems'

Deselect all items. It uses deselectAll.

Parameters:
id - ID of the list.
Author:
QFS
Since:
3.1.1
Procedure: 'deselectItem'

Deselect a given item, specified by its index. It uses deselect.

Parameters:
id - ID of the list.
item - The index of the item.
Author:
QFS
Since:
3.1.1
Procedure: 'deselectItemRange'

Deselect a range of items, specified by their index. It uses deselect.

Parameters:
id - ID of the list.
startItem - The index of first item to be selected.
endItem - The index of last item to be selected.
Author:
QFS
Since:
3.1.1
Procedure: 'selectAllItems'

Select all items. It uses selectAll.

Parameters:
id - ID of the list.
Author:
QFS
Since:
3.1.1
Procedure: 'selectItem'

Select a given item, specified by its index. It uses select.

Parameters:
id - ID of the list.
row - The index of the item.
Author:
QFS
Since:
3.1.1
Procedure: 'selectItemRange'

Select a range of items, specified by their index. It uses select.

Parameters:
id - ID of the list.
startItem - The index of first item to be selected.
endItem - The index of last item to be selected.
Author:
QFS
Since:
3.1.1
Package: 'menu'

Procedures to select menu items and checkbox menu items. (SWT components org.eclipse.swt.widgets.MenuItem from org.eclipse.swt.widgets.Menu)

Author:
QFS
Since:
2.1.0
Procedure/DependencyDescription
ProcedureselectItem
Select an item from a menu.
ProcedureselectSubItem
Select an item within a submenu.
ProceduresetCheckItem
Select a checkbox menu item.
ProceduresetSubCheckItem
Select a checkbox menu item within within a submenu.
Procedure: 'selectItem'

Select an item from a menu.

For example: for the File -> Open action, the component ID of "File" is the menu, and the ID for "Open" is the item.

Parameters:
client - The name of the SUT client.
menu - The id of the menu.
item - The id of menu item.
Author:
QFS
Since:
2.1.0
Procedure: 'selectSubItem'

Select an item within a submenu.

For example: for the View -> Terminal -> Show action, the component ID of "View" is the menu, the ID for "Terminal" is the item, and the ID for "Show" is the sub-item to select.

Parameters:
client - The name of the SUT client.
menu - The id of the menu.
item - The id of the item to open the submenu.
subItem - The id of item in submenu.
Author:
QFS
Since:
2.1.0
Procedure: 'setCheckItem'

Select a checkbox menu item.

For example: for the View -> Show Details action, the component ID of "View" is the menu, and the ID for "Show Details" is the checbox item to set (to true or false).

Parameters:
client - The name of the SUT client.
menu - The id of the menu.
checkItem - The id of the checkbox item.
checkItemValue - The check item value to be set - 'true' to select the checkbox item (default), 'false' to deselect.
Author:
QFS
Since:
2.1.0
Procedure: 'setSubCheckItem'

Select a checkbox menu item within within a submenu.

For example: for the View -> Terminal -> Wrap Lines action, the component ID of "View" is the menu, the ID for "Terminal" is the item and the ID for "Wrap Lines" is the checkbox menu item to set (to true or false).

Parameters:
client - The name of the SUT client.
menu - The id of the menu.
item - The id of the item to open the submenu.
subCheckItem - The id of the checkbox item in the submenu.
checkItemValue - The checkbox item value to be set - "true" to select the checkbox item (default), "false" to deselect.
Author:
QFS
Since:
2.1.0
Package: 'popupmenu'

Procedures to select items and checkbox menu items from popup menus.

Note that for all procedures, the popup menu must first be opened by the calling test-suite, as the popup menu is component-dependent.

See package "menu" for more details about menus and sub-menus. (SWT components org.eclipse.swt.widgets.MenuItem from org.eclipse.swt.widgets.Menu)

Author:
QFS
Since:
2.1.0
Procedure/DependencyDescription
ProcedureselectItem
Select an item in a popup menu.
ProcedureselectSubItem
Select an item within a submenu of a popup menu.
ProceduresetCheckItem
Select a checkbox menu item in a popup menu.
ProceduresetSubCheckItem
Select a checkbox menu item within a submenu of a popup menu.
Procedure: 'selectItem'

Select an item in a popup menu.

Parameters:
client - The name of the SUT client.
item - The id of menu item.
Author:
QFS
Since:
2.1.0
Procedure: 'selectSubItem'

Select an item within a submenu of a popup menu.

Parameters:
client - The name of the SUT client.
item - The id of the item to open the submenu.
subItem - The id of item in submenu.
Author:
QFS
Since:
2.1.0
Procedure: 'setCheckItem'

Select a checkbox menu item in a popup menu.

Parameters:
client - The name of the SUT client.
checkItem - The id of the menu checkbox item.
checkItemValue - The checkbox item value to be set - "true" to select the checkbox item (default), "false" to deselect.
Author:
QFS
Since:
2.1.0
Procedure: 'setSubCheckItem'

Select a checkbox menu item within a submenu of a popup menu.

Parameters:
client - The name of the SUT client.
item - The id of item to open the submenu.
subCheckItem - The id of the checkbox item in the submenu.
checkItemValue - The checkbox item value to be set - "true" to select the checkbox item (default), "false" to deselect.
Author:
QFS
Since:
2.1.0
Package: 'sash'

Procedures to work with sash components. (SWT component org.eclipse.swt.widgets.Sash)

Author:
QFS
Since:
2.1.1
Procedure/DependencyDescription
ProceduremoveSash
Move a sash by a given distance.
ProceduremoveSashTo
Move a sash to a given position.
Procedure: 'moveSash'

Move a sash by a given distance.

Parameters:
id - The component-ID of the sash.
distance - The number of pixels to move the sash.
Author:
QFS
Since:
2.1.1
Procedure: 'moveSashTo'

Move a sash to a given position.

Parameters:
id - The component-ID of the sash.
target - The target position for the sash.
Author:
QFS
Since:
2.1.1
Package: 'scrollbar'
Procedure/DependencyDescription
ProcedurepageDown
Scroll a component one page downwards by simulating a hard mouse click below the scrollbar's thumb.
ProcedurepageLeft
Scroll a component one page to the left by simulating a hard mouse click to the left of the scrollbar's thumb.
ProcedurepageRight
Scroll a component one page to the right by simulating a hard mouse click to the right of the scrollbar's thumb.
ProcedurepageUp
Scroll a component one page upwards by simulating a hard mouse click above the scrollbar's thumb.
ProcedurescrollDown
Scroll a component downwards by simulating a hard mouse click on the down arrow button of its vertical scrollbar.
ProcedurescrollLeft
Scroll a component to the left by simulating a hard mouse click on the left arrow button of its horizontal scrollbar.
ProcedurescrollRight
Scroll a component to the right by simulating a hard mouse click on the right arrow button of its horizontal scrollbar.
ProcedurescrollUp
Scroll a component upwards by simulating a hard mouse click on the up arrow button of its vertical scrollbar.
Procedure: 'pageDown'

Scroll a component one page downwards by simulating a hard mouse click below the scrollbar's thumb.

Parameters:
id - The id of the component to scroll.
parentId - The id of the parent component.
Exceptions:
UserException - If no horizontal scrollbar is visible.
Procedure: 'pageLeft'

Scroll a component one page to the left by simulating a hard mouse click to the left of the scrollbar's thumb.

Parameters:
id - The id of the component to scroll.
parentId - The id of the parent component.
Exceptions:
UserException - If no horizontal scrollbar is visible.
Procedure: 'pageRight'

Scroll a component one page to the right by simulating a hard mouse click to the right of the scrollbar's thumb.

Parameters:
id - The id of the component to scroll.
parentId - The id of the parent component.
Exceptions:
UserException - If no horizontal scrollbar is visible.
Procedure: 'pageUp'

Scroll a component one page upwards by simulating a hard mouse click above the scrollbar's thumb.

Parameters:
id - The id of the component to scroll.
parentId - The id of the parent component.
Exceptions:
UserException - If no horizontal scrollbar is visible.
Procedure: 'scrollDown'

Scroll a component downwards by simulating a hard mouse click on the down arrow button of its vertical scrollbar.

Parameters:
id - The id of the component to scroll.
parentId - The id of the parent component.
Exceptions:
UserException - If no horizontal scrollbar is visible.
Procedure: 'scrollLeft'

Scroll a component to the left by simulating a hard mouse click on the left arrow button of its horizontal scrollbar.

Parameters:
id - The id of the component to scroll.
parentId - The id of the parent component.
Exceptions:
UserException - If no horizontal scrollbar is visible.
Procedure: 'scrollRight'

Scroll a component to the right by simulating a hard mouse click on the right arrow button of its horizontal scrollbar.

Parameters:
id - The id of the component to scroll.
parentId - The id of the parent component.
Exceptions:
UserException - If no horizontal scrollbar is visible.
Procedure: 'scrollUp'

Scroll a component upwards by simulating a hard mouse click on the up arrow button of its vertical scrollbar.

Parameters:
id - The id of the component to scroll.
parentId - The id of the parent component.
Exceptions:
UserException - If no horizontal scrollbar is visible.
Package: 'tabfolder'

Procedures for SWT TabFolder widgets. (SWT component org.eclipse.swt.widgets.TabFolder)

Author:
QFS
Since:
2.2.0
Procedure/DependencyDescription
ProcedurecloseTab
Close a tab via sending a "close" selection event.
ProcedureselectTab
Select a tab in a given Tabfolder.
Procedure: 'closeTab'

Close a tab via sending a "close" selection event.

Parameters:
client - The name of the SUT client.
id - The component-if of the tabfolder to select.
separator - Separator to use for the tab syntax. Default is @ for text values, also available & for index and % for regexp.
value - The value to select.
Author:
QFS
Since:
2.2.0
Procedure: 'selectTab'

Select a tab in a given Tabfolder.

Parameters:
client - The name of the SUT client.
id - The component-if of the tabfolder to select.
separator - Separator to use for the tab syntax. Default is @ for text values, also available & for index and % for regexp.
value - The value to select.
Author:
QFS
Since:
2.2.0
Package: 'table'

Procedures to access tables. (SWT component org.eclipse.swt.widgets.Table)

Author:
QFS
Since:
2.1.0
Procedure/DependencyDescription
ProceduregetColumnCount
Return the number of columns of a given table.
ProceduregetNameOfColumn
Return the header text of a given column.
ProceduregetRowCount
Return the number of rows of a given table.
ProceduregetValueOfCell
Return the text of a given cell.
ProcedureselectCell
Select a given cell.
Procedure: 'getColumnCount'

Return the number of columns of a given table. It uses the method getColumnCount() do get the number.

Parameters:
id - The component-ID of the table.
Returns:
columnCount
Author:
QFS
Since:
2.1.0
Procedure: 'getNameOfColumn'

Return the header text of a given column.

Sample usage: Determine the title of the second colum.

Parameters:
id - ID of the table.
column - The column.
columnSeparator - Separator to use for the column syntax. Default is @ for text values, also available & for index and % for regexp.
Returns:
name The name of the column.
Author:
QFS
Since:
3.1.1
Procedure: 'getRowCount'

Return the number of rows of a given table. It uses the method Table.getItemCount() to get the number.

Parameters:
id - The component-ID of the table.
Returns:
rowCount
Author:
QFS
Since:
2.1.0
Procedure: 'getValueOfCell'

Return the text of a given cell.

Sample usage: Can be used to determine the text of the cell in the first column and first row.

Parameters:
id - ID of the table.
column - The column.
row - The row.
columnSeparator - Separator to use for the column syntax. Default is @ for text values, also available & for index and % for regexp.
rowSeparator - Separator to use for the row syntax. Default is @ for text values, also available & for index and % for regexp.
Returns:
value The current value of the row, which has been read by the 'Fetch text' node of QF-Test.
Author:
QFS
Since:
3.1.1
Procedure: 'selectCell'

Select a given cell.

Parameters:
id - ID of the table.
column - The column.
row - The row.
columnSeparator - Separator to use for the column syntax. Default is @ for text values, also available & for index and % for regexp.
rowSeparator - Separator to use for the node syntax. Default is @ for text values, also available & for index and % for regexp.
Author:
QFS
Since:
2.1.0
Package: 'checks'

Procedures for checking a table.

Author:
QFS
Since:
3.1.1
Procedure/DependencyDescription
ProcedurecheckNumberOfRows
Check the number of rows of a given table according to a specified comparison mode.
Procedure: 'checkNumberOfRows'

Check the number of rows of a given table according to a specified comparison mode. It uses the method Table.getItemCount() to get the number.

Sample usage: You can check, that a table has exactly 6 rows or that the table has less then 10 rows.

Parameters:
id - The id of the table.
compareValue - The comparison value.
compareMode - The comparison mode =, if the compareValue should be equal than the actual amount of rows. <, if the compareValue should be greater than the actual amount of rows. >, if the compareValue should be less than the actual amount of rows. <=, if the compareValue should be greater or equal than the actual amount of rows. >=, if the compareValue should be less or equal the actual amount of rows.
errorLevel - The kind of error, which should be logged. Either EXCEPTION, ERROR, WARNING or MESSAGE.
appearInReport - Flag, whether to show check in report, if a message or warning are set as errorLevel. If this is set to 1, the check will be shown in the report.
Exceptions:
UserException, - if wrong comparison mode has been set.
Author:
QFS
Since:
3.1.1
Package: 'selection'

Procedures to (de-)select certain rows of a table.

Author:
QFS
Since:
2.1.0
Procedure/DependencyDescription
ProceduredeselectAllRows
Deselect all rows.
ProceduredeselectRow
Deselect a given row, specified by its index.
ProceduredeselectRowRange
Deselect a range of rows, specified by their index.
ProcedureselectAllRows
Select all rows.
ProcedureselectRow
Select a given row, specified by its index.
ProcedureselectRowRange
Select a range of rows, specified by their index.
Procedure: 'deselectAllRows'

Deselect all rows. It uses deselectAll().

Parameters:
id - ID of the table.
Author:
QFS
Since:
2.1.0
Procedure: 'deselectRow'

Deselect a given row, specified by its index. It uses deselect().

Parameters:
id - ID of the table.
row - The index of the row.
Author:
QFS
Since:
2.1.0
Procedure: 'deselectRowRange'

Deselect a range of rows, specified by their index. It uses deselect().

Parameters:
id - ID of the table.
startRow - The index of first row to be selected.
endRow - The index of last row to be selected.
Author:
QFS
Since:
2.1.0
Procedure: 'selectAllRows'

Select all rows. It uses selectAll().

Parameters:
id - ID of the table.
Author:
QFS
Since:
2.1.0
Procedure: 'selectRow'

Select a given row, specified by its index. It uses select().

Parameters:
id - ID of the table.
row - The index of the row.
Author:
QFS
Since:
2.1.0
Procedure: 'selectRowRange'

Select a range of rows, specified by their index. It uses select().

Parameters:
id - ID of the table.
startRow - The index of first row to be selected.
endRow - The index of last row to be selected.
Author:
QFS
Since:
2.1.0
Package: 'text'

Procedures to access text fields and text areas. It should work with any SWT components representing textfields or textareas, e.g. org.eclipse.swt.custom.StyledText or org.eclipse.swt.widgets.Text.

Author:
QFS
Since:
2.1.0
Procedure/DependencyDescription
ProcedureclearArea
Clear a multi-line text area.
ProcedureclearField
Clear a simple text field.
ProceduresetText
Set a given text to a given text-field or text-area.
ProceduresetTextFromFile
Read the content of a given file and set its content to a given text-field.
Procedure: 'clearArea'

Clear a multi-line text area.

Parameters:
client - The name of the SUT client.
id - The id of the text area.
Author:
QFS
Since:
2.1.0
Procedure: 'clearField'

Clear a simple text field.

Parameters:
client - The name of the SUT client.
id - The id of the text field.
Author:
QFS
Since:
2.1.0
Procedure: 'setText'

Set a given text to a given text-field or text-area.

If the text is empty, no action will take place.

Parameters:
id - ID of the textfield.
text - text to be set.
append - if this value is set to true, the text will be appended to the current values.
clear - If this value is set to true, the text-field will be cleared in case an empty string is given as parameter "text".
replaySingleEvents - If this value is set to true, the text will be inserted replaying single events.
newline - the separator sign for marking a linebreak within the text
Author:
QFS
Since:
2.1.0
Procedure: 'setTextFromFile'

Read the content of a given file and set its content to a given text-field.

Parameters:
id - The id of the text-field to set.
file - The path to the file.
Author:
QFS
Since:
3.1.1
Package: 'tree'

Procedures to access trees. (SWT component org.eclipse.swt.widgets.Tree)

Author:
QFS
Since:
2.1.0
Procedure/DependencyDescription
ProcedurecallbackPrintNodeText
Example for a callback procedure used by expandNodes.
Procedurecollapse
Collapse a tree node.
ProcedurecollapseNode
Collapse a tree node.
Procedureexpand
Expand a tree node.
ProcedureexpandNode
Expand a tree node.
ProcedureexpandNodes
Expand a tree node recursively.
ProceduregetRowCount
Return the number of rows of a given tree.
ProceduregetValueOfNode
Return the text of a given node.
ProcedureselectNode
Select a given node.
Procedure: 'callbackPrintNodeText'

Example for a callback procedure used by expandNodes.

Parameters:
treeId - The id of the tree.
node - The index of the node.
Author:
QFS
Since:
3.0
Procedure: 'collapse'

Collapse a tree node.

Parameters:
client - The name of the SUT client.
node - The id of the tree node to collapse.
Author:
QFS
Since:
2.1.0
Procedure: 'collapseNode'

Collapse a tree node.

Parameters:
client - The name of the SUT client.
id - The id of the tree.
node - The node.
separator - Separator to use for the node syntax. Default is @ for text values, also available & for index and % for regexp.
Author:
QFS
Since:
3.0
Procedure: 'expand'

Expand a tree node.

Parameters:
client - The name of the SUT client.
node - The id of the tree node to expand.
Author:
QFS
Since:
2.1.0
Procedure: 'expandNode'

Expand a tree node.

Parameters:
client - The name of the SUT client.
id - The id of the tree.
node - The node.
separator - Separator to use for the node syntax. Default is @ for text values, also available & for index and % for regexp.
Author:
QFS
Since:
3.0
Procedure: 'expandNodes'

Expand a tree node recursively.

Parameters:
id - The id of the tree node.
callbackProc - The name of a procedure to be called for every visited node.
Author:
QFS
Since:
3.0
Procedure: 'getRowCount'

Return the number of rows of a given tree. It uses the method Tree.getItemCount() to get the number.

Parameters:
id - The component-id of the tree.
Returns:
rowCount
Author:
QFS
Since:
3.1.1
Procedure: 'getValueOfNode'

Return the text of a given node.

Sample usage: Determine the text value for a node referenced by index like /0/1.

Parameters:
id - ID of the tree.
node - The node. It should be something like '/Root/Price' or '/0/0'.
nodeSeparator - Separator to use for the node syntax. Default is @ for text values, also available & for index and % for regexp.
Returns:
The value of the node.
Author:
QFS
Since:
3.1.1
Procedure: 'selectNode'

Select a given node.

Parameters:
id - The id of the tree.
node - The node.
separator - Separator to use for the node syntax. Default is @ for text values, also available & for index and % for regexp.
Author:
QFS
Since:
2.1.0
Package: 'checks'

Procedures for checking a tree.

Author:
QFS
Since:
3.1.1
Procedure/DependencyDescription
ProcedurecheckNumberOfRows
Check the number of visilble rows of a given tree according to a specified comparison mode.
Procedure: 'checkNumberOfRows'

Check the number of visilble rows of a given tree according to a specified comparison mode. It uses Tree.getItemCount() to determine the current number of rows.

Sample usage: You can check, that a tree has exactly 6 visible rows or that the tree has less then 10 visible rows.

Parameters:
id - The id of the tree.
compareValue - The comparison value.
compareMode - The comparison mode =, if the compareValue should be equal than the actual amount of rows. <, if the compareValue should be greater than the actual amount of rows. >, if the compareValue should be less than the actual amount of rows. <=, if the compareValue should be greater or equal than the actual amount of rows. >=, if the compareValue should be less or equal the actual amount of rows.
errorLevel - The kind of error, which should be logged. Either EXCEPTION, ERROR, WARNING or MESSAGE.
appearInReport - Flag, whether to show check in report, if a message or warning are set as errorLevel. If this is set to 1, the check will be shown in the report.
Exceptions:
UserException, - if wrong comparison mode has been set.
Author:
QFS
Since:
3.1.1
Package: 'utils'

Miscellaneous utility procedures.

Author:
QFS
Since:
2.1.0
Procedure/DependencyDescription
ProcedurecreateThreadDump
Trigger a full thread dump in the SUT if possible.
ProceduredumpHeap
Dump the heap of the Java VM.
ProceduregetDate
Return a date, default is the current date in current locale.
ProceduregetTime
Return the time in the current format.
ProceduregetTimestamp
Return a timestamp, which reprents the current time in milliseconds.
ProcedurekillAllClients
Kill all running clients.
ProcedurekillClient
Kill a client.
ProcedurelogAllMethodsOfAGivenComponent
Log all available methods of a given component.
ProcedurelogMemory
Log current memory use.
ProcedureprintMessage
Print a given message to STDOUT.
ProcedureprintVariable
Print the content of a variable.
ProcedurereadTextFromFile
Read the content of a given file.
ProceduresendEmail
ProcedurewriteMessageIntoFile
Write a given message into a given file.
Procedure: 'createThreadDump'

Trigger a full thread dump in the SUT if possible.

Parameters:
client - The name of the SUT client.
Author:
QFS
Since:
3.4
Procedure: 'dumpHeap'

Dump the heap of the Java VM.

Parameters:
sut - True to dump the SUT heap for $(client), false for the QF-Test heap.
client - The name ot the SUT client in case sut is true.
file - The name ot the file to dump the heap to.
deleteFirst - Whether to delete the file first. Otherwise an existing file will not be overwritten.
Author:
QFS
Since:
3.4
Procedure: 'getDate'

Return a date, default is the current date in current locale.

Parameters:
format - The format of the date, default is the current locale. You can specify this via the SimpleDateFormat in Java, e.g. MM/dd/yyyy. dd means two digits for the day. MM means two digits for month. yyyy means four digits for year.
offset - The number of days in future/past. For yesterday's date specify -1. For tomorrow's date specify 1.
Returns:
date The date in specified format.
Author:
QFS,mm
Since:
2.1.0
Procedure: 'getTime'

Return the time in the current format. Default is now, timestamps in the past or in future can be specified via the offset parameter.

Parameters:
format - The format of the date, default HH:mm:ss. hh means two digits for the hour. mm means two digits for minutes. ss means two digits for seconds.
offset - The seconds in future/past. For one minute ago specify -60. For one minute in future specify +60.
timezone - The timezone to get the time from. If left empty, the local time will be taken
Returns:
The time in specified format.
Author:
QFS,,mm, Denis Gauthier
Since:
2.1.0, 3.1.4
Procedure: 'getTimestamp'

Return a timestamp, which reprents the current time in milliseconds.

Returns:
The timestmap in milliseconds.
Author:
QFS,mm
Since:
3.3.0
Procedure: 'killAllClients'

Kill all running clients.

Parameters:
timeout - The timeout for waiting for process termination after killing a client.
Exceptions:
ClientNotTerminatedException - if a client has not been killed.
Author:
QFS,mm
Since:
3.1.1
Procedure: 'killClient'

Kill a client.

Parameters:
client - The connection.
timeout - The timeout for waiting for process termination after killing.
Exceptions:
ClientNotTerminatedException - if a client has not been killed.
Author:
QFS,mm
Since:
3.1.1
Procedure: 'logAllMethodsOfAGivenComponent'

Log all available methods of a given component. This script can be used to look for dedicated methods of objects. NOTE: If you use custom classloaders, the procedure could fail.

Parameters:
id - The id of the component.
Author:
QFS,mm
Since:
3.1.1
Procedure: 'logMemory'

Log current memory use.

Parameters:
sut - True to log SUT memory for $(client), false for qftest memory.
client - The name ot the SUT client in case sut is true.
warningLimit - Optional value in MB. If exceeded, log a warning instead of a plain message.
errorLimit - Optional value in MB. If exceeded, log an error instead of a warning or a plain message.
Author:
QFS
Since:
2.1.0
Procedure: 'printMessage'

Print a given message to STDOUT.

Parameters:
message - The message to be printed.
Author:
QFS,mm
Since:
2.1.0
Procedure: 'printVariable'

Print the content of a variable.

Parameters:
variableName - The name of the variable.
Author:
QFS,mm
Since:
2.1.0
Procedure: 'readTextFromFile'

Read the content of a given file.

Parameters:
file - The path to the file.
Returns:
The contents of the file.
Exceptions:
UserException, - if files doesn't exist.
Author:
QFS,mm
Since:
3.1.1
Procedure: 'sendEmail'

Deprecated. Use qfs.utils.email.sendEmail or qfs.utils.email.sendEmail_SMTPHost instead.

Author:
QFS
Since:
2.9.1
Procedure: 'writeMessageIntoFile'

Write a given message into a given file. NOTE: You cannot use special characters like \n or \t in the message.

Parameters:
client - The name of the SUT client.
message - The message, which should be written.
file - The file, where the message has to be written into.
addLinebreak - If this is set to true, a linebreak `\n` will be appended to the text.
Exceptions:
UserException, - if no proper values for file and message have been set.
Author:
QFS,mm
Since:
2.1.0
Package: 'clipboard'

Accessing the clipboard from procedures.

Author:
QFS
Since:
3.4.0
Procedure/DependencyDescription
ProceduregetTextFromClipboard
Return the current text on the system clipboard.
Procedure: 'getTextFromClipboard'

Return the current text on the system clipboard.

Returns:
The current text on the clipboard.
Author:
QFS,mm
Since:
3.4.0
Package: 'email'

Procedures for sending E-Mails.

Author:
QFS
Since:
3.1.2
Procedure/DependencyDescription
ProceduresendEmail
Send an e-mail.
ProceduresendEmail_SMTPHost
Send an e-mail.
Procedure: 'sendEmail'

Send an e-mail. This procedure uses the smtplib module from Jython, which requires a SMTP server on localhost for sending e-mails.

It is possible that you have to copy that script and use it as template for your own script, because your mail-server requires a different authentication.

Parameters:
from - The address of the sender.
to - A comma-separated list of recipients.
subject - The subject of the e-mail.
text - The text of the e-mail.
Exceptions:
Exception - If something went wrong
Author:
QFS
Since:
3.1.2
Procedure: 'sendEmail_SMTPHost'

Send an e-mail. This procedure uses the smtplib module from Jython, which requires a SMTP server for sending e-mails. This procedure performs a login of a given user to a given SMTP server before sending the e-mail.

It is possible that you have to copy that script and use it as template for your own script, because your mail-server requires a different authentication.

Parameters:
from - The address of the sender.
to - A comma-separated list of recipients.
subject - The subject of the e-mail.
text - The text of the e-mail.
smtpHost - SMTP server for sending e-mails.
smtpUser - User for the SMTP server.
smtpPassword - Password for the SMTP server.
Exceptions:
Exception - If something went wrong
Author:
QFS
Since:
3.1.2
Package: 'pop3'

Procedures for interacting with a POP3 server.

Author:
QFS
Since:
3.1.3
Procedure/DependencyDescription
ProceduredeleteMessages
Delete all messages from a pop3 account.
ProcedurefetchMessage
Fetch a message from a pop3 account.
Procedure: 'deleteMessages'

Delete all messages from a pop3 account.

Parameters:
host - Hostname of the pop3 server.
port - Optional port of the pop3 server, leave empty to use the standard port.
username - Username for the pop3 account.
password - Password for the pop3 account.
Procedure: 'fetchMessage'

Fetch a message from a pop3 account.

Parameters:
host - Hostname of the pop3 server.
port - Optional port of the pop3 server, leave empty to use the standard port.
username - Username for the pop3 account.
password - Password for the pop3 account.
number - Optional number of the message to get, default 1.
delete - Whether to delete the message, default true.
timeout - Approximate maximum time in ms to wait for the message to appear.
Package: 'files'

Contain procedures to work with files.

Author:
QFS
Since:
3.4.0
Procedure/DependencyDescription
ProcedurecheckFileForContent
Check, whether a given file contain a specific value.
ProcedurecheckFileForExistingLine
Check, whether a given file contain a specific value in a line.
Procedure: 'checkFileForContent'

Check, whether a given file contain a specific value. The value has to be a regular expression. It checks the whole text of the file for the value, so you can also specify text containing line breaks, if required.

Parameters:
fileName - The filename to check.
value - The value for checking.
errorLevel - The kind of error, which should be logged. Either EXCEPTION, ERROR, WARNING or MESSAGE.
appearInReport - Flag, whether to show check in report, if a message or warning are set as errorLevel. If this is set to 1, the check will be shown in the report.
Exceptions:
UserException, - if file doesn't exist.
Author:
QFS,mm
Since:
3.4.0
Procedure: 'checkFileForExistingLine'

Check, whether a given file contain a specific value in a line. If valueRegex is set to true, it checks for a regular expression. If valueRegex is set to false the text has in a row has to match exactly.

Parameters:
fileName - The filename to check.
value - The value for checking.
valueRegex - True, if the value is a regex, otherwise false.
errorLevel - The kind of error, which should be logged. Either EXCEPTION, ERROR, WARNING or MESSAGE.
appearInReport - Flag, whether to show check in report, if a message or warning are set as errorLevel. If this is set to 1, the check will be shown in the report.
Exceptions:
UserException, - if file doesn't exist.
Author:
QFS,mm
Since:
3.4.0
Package: 'random'

Procedures for generating random string.

Author:
QFS
Since:
3.0
Procedure/DependencyDescription
ProceduregetEntriesOfArea
Return a random string created of parts of a specified area.
ProceduregetNumber
Return a random number.
ProceduregetNumberFromRange
Return a random number between two given numbers.
ProceduregetString
Return a random string containing small letters.
Procedure: 'getEntriesOfArea'

Return a random string created of parts of a specified area. The length of the string can also be specified as parameter.

Parameters:
area - The area, which contains the choices.
length - The length of the random string.
Returns:
string The random string.
Author:
QFS,mm
Since:
3.0
Procedure: 'getNumber'

Return a random number.

Parameters:
length - The length of the random string.
Returns:
number The random number.
Author:
QFS,mm
Since:
3.0
Procedure: 'getNumberFromRange'

Return a random number between two given numbers.

If you call it with lowest 0 and highest 3. The procedure could return 0, 1 or 2.

Parameters:
lowest - The lowest number for the random choice. It could be returned.
highest - The highes number for the random choice. It won't be included.
Returns:
random The random number.
Author:
QFS,mm
Since:
3.4.0
Procedure: 'getString'

Return a random string containing small letters.

Parameters:
length - The length of the random string.
Returns:
string The random string.
Author:
QFS,mm
Since:
3.0
Package: 'testrun'

Procedures for handling the test execution.

Author:
QFS
Since:
3.1.3
Package: 'skip'

Procedures for skipping test-steps.

Author:
QFS
Since:
3.1.3
Procedure/DependencyDescription
ProcedureskipTestCase
Skip the execution of the current test-case.
ProcedureskipTestSet
Skip the execution of the current test-set.
Procedure: 'skipTestCase'

Skip the execution of the current test-case.

Author:
QFS,mm
Since:
3.1.3
Procedure: 'skipTestSet'

Skip the execution of the current test-set.

Author:
QFS,mm
Since:
3.1.3
Package: 'stop'

Procedures for stopping test-steps.

Author:
QFS
Since:
3.1.3
Procedure/DependencyDescription
ProcedurestopTestCase
Stop the execution of the current test-case
ProcedurestopTestRun
Stop the complete test-run.
ProcedurestopTestSet
Stop the execution of the current test-set.
Procedure: 'stopTestCase'

Stop the execution of the current test-case

Parameters:
expectedToFail - Whether test-case was expected to fail.
Author:
QFS,mm
Since:
3.1.3
Procedure: 'stopTestRun'

Stop the complete test-run.

Author:
QFS,mm
Since:
3.1.3
Procedure: 'stopTestSet'

Stop the execution of the current test-set.

Author:
QFS,mm
Since:
3.1.3
Package: 'variables'

Procedures for working with variables.

Author:
QFS
Since:
3.3.0
Procedure/DependencyDescription
ProceduredeleteAllGlobalVariables
Delete all global QF-Test variables.
ProceduredeleteOneGlobalVariable
Delete a given global QF-Test variable.
Procedure: 'deleteAllGlobalVariables'

Delete all global QF-Test variables.

Author:
QFS,mm
Since:
3.3.0
Procedure: 'deleteOneGlobalVariable'

Delete a given global QF-Test variable.

Parameters:
variableName - The name of the variable.
Author:
QFS,mm
Since:
3.3.0
Package: 'xml'

Procedures for working with XML files.

Author:
QFS
Since:
3.1.1
Procedure/DependencyDescription
ProcedurecompareXMLFiles
Compare two XML files for full identity.
Procedure: 'compareXMLFiles'

Compare two XML files for full identity. It writes an error for each different tag, if differences were found. The script uses a DOM parser, which could cause memory troubles for huge XML files!

If you want to compare the XML structure of two XML files, but you don't want to compare the content of a tag, e.g. '', then you can specify that tag in the 'noCheck' parameter, like 'date' (without quotes). Now any tag will be compared but ''.

Parameters:
originalFile - The original file for comparison.
compareFile - The file for comparing.
noCheck - A comma separated list of tags, which are excluded for checking.
Exceptions:
UserException, - if one of the given files don't exist.
Author:
QFS,mm
Since:
3.1.1
Package: 'web'

Web utility procedures.

Author:
QFS
Since:
2.9.0
Package: 'ajax'

AJAX procedures.

Author:
QFS
Since:
3.3.0
Procedure/DependencyDescription
ProcedureinstallToolkitResolver
Installs a special resolver for given AJAX toolkit to improve recorded component types and hierarchy and therefore achieves improved component recognition.
Procedure: 'installToolkitResolver'

Installs a special resolver for given AJAX toolkit to improve recorded component types and hierarchy and therefore achieves improved component recognition.

Parameters:
toolkit - The AJAX toolkit. Currently supported are extjs, extgwt, gwt, qooxdoo, rap and richfaces.
resolver_version - The resolver version, e.g. 1 or 1.0 or 1.1.1. The latest possible version with the given restriction will be used, e.g. if 1.0 is given, than the latest 1.0.x will apply. If empty, latest available version will be used.
Author:
QFS
Since:
3.3.0
Package: 'browser'

Browser procedures.

Author:
QFS
Since:
2.9.0
Package: 'dialogs'

Procedures for handling Error-Dialogs opened within the Browser.

Author:
itcampus
Since:
2.9.1
Procedure/DependencyDescription
ProcedurecloseCertificateWarning
Uses the Java AWT Robot Methods to automatically close an open Certificate Warning Dialog.
ProcedurecloseJavascriptWarning
Uses the Java AWT Robot Methods to automatically close an open Javascript Warning Dialog.
Procedureupload
Handle the native Windows Upload dialog (especially for Internet Explorer 8).
Procedure: 'closeCertificateWarning'

Uses the Java AWT Robot Methods to automatically close an open Certificate Warning Dialog.

Parameters:
browser - The browser.
Author:
itcampus
Since:
2.9.1
Procedure: 'closeJavascriptWarning'

Uses the Java AWT Robot Methods to automatically close an open Javascript Warning Dialog.

Author:
itcampus
Since:
2.9.1
Procedure: 'upload'

Handle the native Windows Upload dialog (especially for Internet Explorer 8).

Parameters:
filename - The name of the file to be uploaded.
title - A regexp for the title of the dialog.
button - A regexp for the text on the open button.
Author:
QFS
Since:
3.2
Package: 'dom'

Procedures for handling DOM access.

Author:
itcampus
Since:
2.9.1
Procedure/DependencyDescription
ProcedureselectAllCheckboxes
Checks or unchecks all (enabled) Checkboxes which are situated in the DOM-Tree beneath the given Parent.
Procedure: 'selectAllCheckboxes'

Deprecated. Use qfs.web.checkbox.setAll instead.

Checks or unchecks all (enabled) Checkboxes which are situated in the DOM-Tree beneath the given Parent. In most of the cases the parent should be set to the form-Element which contains the checkboxes.

Parameters:
parent - The parent Element.
select - If set to false, all Checkboxes are unchecked.
Author:
itcampus
Since:
2.9.1
Package: 'general'

General browser procedures.

Author:
QFS
Since:
2.9.0
Procedure/DependencyDescription
ProcedurecheckForRunningBrowserEngine
Check for the browser and if is not running than start it.
ProcedureisIE6
Checks if running Browser-Engine has embedded Internet Explorer 6.
ProcedureopenNewWindow
Open a new window in an already running browser.
ProcedureshowUrl
Show a different URL in an open browser window.
ProcedurestartAsNewProcess
Ensures the given browser executable is started as a new process.
Procedure: 'checkForRunningBrowserEngine'

Check for the browser and if is not running than start it.

Parameters:
client - The client.
browser - The browser.
mozhome - The Mozilla installation directory (optional).
mozprofile - The directory to store the profile data (optional).
Author:
QFS
Since:
2.9.0
Procedure: 'isIE6'

Checks if running Browser-Engine has embedded Internet Explorer 6.

If true it sets the global variable "isIE6" to true.

Parameters:
client - The client.
Author:
itcampus
Since:
2.9.1
Procedure: 'openNewWindow'

Open a new window in an already running browser.

Parameters:
client - The client.
browser - The type of Browser (ie, mozilla,...).
url - The URL to open in the new window.
windowname - The name of the new window. (optional)
x - X-Coordinate for the browser window. (optional)
y - Y-Coordinate for the browser window. (optional)
width - Width for the browser window. (optional)
height - Height for the browser window. (optional)
Author:
itcampus
Since:
2.9.1
Procedure: 'showUrl'

Show a different URL in an open browser window.

Parameters:
client - The client.
url - The URL to show.
Author:
itcampus
Since:
2.9.1
Procedure: 'startAsNewProcess'

Ensures the given browser executable is started as a new process. This is especially important when testing an applet in the browser. Otherwise the applet is not properly recognized by QF-Test.

In case there are already running instances of the given browser type, those may need to be terminated. In interactive mode a dialog asks for permission to do so, in batch mode it's simply done.

Parameters:
executable - The browser executable. Possibly the full path is necessary.
browsertype - The browser type that needs special handling: 'firefox' for Firefox, 'chrome' for Google Chrome, 'safari' for Apple Safari, 'ie6' for Internet Explorer 6, (IE7 don't require special handling), 'ie8' for Internet Explorer 8 or higher, 'no' for no special handling.
url - The URL of (typically) the applet.
args - Optional browser arguments. Up to five arguments are currently supported. For chrome the following args may become helpful to avoid blocking after update or on new avaiable java plugins: --always-authorize-plugins --allow-outdated-plugins
dialogTimeout - Timeout value in ms for the dialog in interactive mode. When timeout is reached, test continues with terminating the processes. -1 means infinite waiting time.
Author:
QFS
Since:
3.4
Package: 'mozilla'

Mozilla utility procedures.

Author:
QFS
Since:
2.9.0
Procedure/DependencyDescription
ProcedurecheckGRE
Check whether a Mozilla home directory contains the necessary GRE (Gecko Runtime Environment) files to allow testing.
Procedure: 'checkGRE'

Check whether a Mozilla home directory contains the necessary GRE (Gecko Runtime Environment) files to allow testing. SeaMonkey browsers < version 1.1 used has GRE located under common files which requires manual copying into the browser installation directory.

Parameters:
mozhome - The Mozilla home directory.
Returns:
true in case the a valid GRE is found, false otherwise.
Author:
QFS
Since:
2.9.0
Package: 'settings'

The procedures in this package are useful for customizing browser settings.

Author:
QFS
Since:
2.9.0
Procedure/DependencyDescription
ProceduredeleteCookies
Delete cookies.
ProceduredisableCookies
Disable cookies in the browser.
ProceduredoStartupSettings
Do startup settings for the browser.
ProcedureemptyCache
Empty the browser cache.
ProcedureenableCompatibilityMode
Sets the Compatibility-Mode in Internet Explorer.
ProcedureenableCookies
Enable cookies in the browser.
ProcedureenableMutationListeners
Enable/Disables the MutationListeners in the QF-Test browser engine for a specific document or globally for all documents.
ProceduresetLocale
Set preferred language for in the displaying web pages in the browser.
ProceduresetProxy
Set a proxy server for the browser.
Procedure: 'deleteCookies'

Delete cookies.

Parameters:
client - The name of the SUT client.
browser - The browser.
mozhome - The Mozilla installation directory (optional).
Author:
QFS
Since:
2.9.0
Procedure: 'disableCookies'

Disable cookies in the browser.

Parameters:
client - The name of the SUT client.
browser - The browser.
mozhome - The Mozilla installation directory (optional).
Author:
QFS
Since:
2.9.0
Procedure: 'doStartupSettings'

Do startup settings for the browser. This procedure is used by the Quickstart Wizard.

Parameters:
client - The name of the SUT client.
browser - The browser.
mozhome - The Mozilla installation directory (optional).
mozprofile - The folder to store the profile-data(optional).
compatibiltymode - Set the compatibilitymode for Internet Explorer
emptyCache - true, to enable caching.
enableCookies - true, to allow cookies.
deleteCookies - true, to delete stored cookies.
locale - The locale to be used.
enableProxy - true to enable proxy settings
proxyAddress - Optional address for a proxy server.
proxyPort - Optional port for a proxy server.
Author:
QFS
Since:
2.9.0
Procedure: 'emptyCache'

Empty the browser cache.

Parameters:
client - The name of the SUT client.
browser - The browser.
mozhome - The Mozilla installation directory (optional).
Author:
QFS
Since:
2.9.0
Procedure: 'enableCompatibilityMode'

Sets the Compatibility-Mode in Internet Explorer. (This procedure is only working at browser startup)

Parameters:
client - The name of the SUT client.
browser - The browser.
mozhome - The Mozilla installation directory (optional).
compatibilitymode - The compatibility mode (either "ie7", "ie8", or "ie9")
Author:
QFS
Since:
3.3.0
Procedure: 'enableCookies'

Enable cookies in the browser.

Parameters:
client - The name of the SUT client.
browser - The browser.
mozhome - The Mozilla installation directory (optional).
Author:
QFS
Since:
2.9.0
Procedure: 'enableMutationListeners'

Enable/Disables the MutationListeners in the QF-Test browser engine for a specific document or globally for all documents.

Parameters:
client - The name of the SUT client.
browser - The browser.
mozhome - The Mozilla installation directory (optional).
documentId - If empty or not present, enable/disable works globally for all document. Otherwise for the documentId given
enable - enable/disable MutationListener
forceRescanOnEnable - force a DOM Rescan after enabling the Mutation Listener
Author:
QFS
Since:
3.4.0.
Procedure: 'setLocale'

Set preferred language for in the displaying web pages in the browser.

Parameters:
client - The name of the SUT client.
browser - The browser.
mozhome - The Mozilla installation directory (optional).
locale - The locale, i.e. en for english, en-us for english/United States.
Author:
QFS
Since:
2.9.0
Procedure: 'setProxy'

Set a proxy server for the browser.

Parameters:
client - The name of the SUT client.
browser - The browser.
mozhome - The Mozilla installation directory (optional).
address - The address of the proxy server.
port - The port of the proxy server.
activate - 1 to activate these proxy settings, 0 to deactivate the proxy.
autoconfigurl - URL to get the proxy configuration from.
type - Type of proxy (is empty by default). Type is determined through address, autoconfigurl and activate parameters. Possible values to override default behavior proxy off = 0 ; proxy on = 1; user autoconfig proxy url = 2; auto detect proxy = 4; use system proxy settings = 5;
Author:
QFS,tmax
Since:
3.0.1
Package: 'checkbox'

Procedures to set the state of checkboxes. (Web component INPUT:CHECKBOX)

Author:
QFS
Since:
3.0
Procedure/DependencyDescription
Proceduredeselect
Deselect a checkbox.
Procedureselect
Select a checkbox.
Procedureset
Set checkbox to the given state.
ProceduresetAll
Set all (enabled) checkboxes inside a given parent.
Procedure: 'deselect'

Deselect a checkbox. If the checkbox is already de-selected, no action is performed.

Parameters:
client - The name of the SUT client.
id - The id of the check-box.
Author:
QFS
Since:
3.0
Procedure: 'select'

Select a checkbox. If the checkbox is already selected, no action is performed.

Parameters:
client - The name of the SUT client.
id - The id of the check-box.
Author:
QFS
Since:
3.0
Procedure: 'set'

Set checkbox to the given state.

Parameters:
client - The name of the SUT client.
id - The id of the checkbox.
check - The check value to be set (either true or false).
Author:
QFS
Since:
3.0
Procedure: 'setAll'

Set all (enabled) checkboxes inside a given parent. In most of the cases the parent should be set to the form-Element which contains the checkboxes.

Parameters:
parent - The parent element.
check - The check value to be set (either true or false).
Author:
QFS
Since:
3.1.1
Package: 'checks'

Procedures for handling different web checks.

Author:
itcampus
Since:
2.9.1
Procedure/DependencyDescription
ProcedurecheckAttribute
Checks an attribute of a component.
ProcedurecheckElements(negative)
Negates a normal Elementcheck in select elements to allow NegationChecks.
ProcedurecheckForElement
Checks if the given element (option-element-text) is in the select-element (combo-box).
ProcedurecheckInvisibility
Negates a normal WaitForComponentCheck to allow VisibilityChecks.
ProcedurecheckText(negative)
Negates a normal Textcheck to allow NegationChecks.
ProcedurecheckTitle
Checks the title of the BrowserWindow.
Procedure: 'checkAttribute'

Checks an attribute of a component.

It writes an error into the run-log, if the check fails.

Parameters:
id - The id of the component.
attribute - The attribute to check.
value - The expected value.
appearInReport - Flag, whether to show check in report, if a message or warning are set as errorLevel. If this is set to 1, the check will be shown in the report.
Author:
itcampus
Since:
2.9.1
Procedure: 'checkElements(negative)'

Negates a normal Elementcheck in select elements to allow NegationChecks.

It writes an error into the run-log, if the check fails.

Parameters:
id - The id of the component.
value - The value that should "NOT" be the Text of one element the Component.
Author:
itcampus
Since:
2.9.1
Procedure: 'checkForElement'

Checks if the given element (option-element-text) is in the select-element (combo-box).

It writes an error into the run-log, if the element is not found.

Parameters:
id - The id of the select-element.
element - The Option-Element-Text.
Author:
itcampus
Since:
2.9.1
Procedure: 'checkInvisibility'

Negates a normal WaitForComponentCheck to allow VisibilityChecks.

It writes an error into the run-log, if the check fails.

Parameters:
id - The id of the component.
Author:
itcampus
Since:
2.9.1
Procedure: 'checkText(negative)'

Negates a normal Textcheck to allow NegationChecks.

It writes an error into the run-log, if the check fails.

Parameters:
id - The id of the component.
value - The value that should "NOT" be the Text of the Component.
reportName - the Name for the check in the report.
Author:
itcampus
Since:
2.9.1
Procedure: 'checkTitle'

Checks the title of the BrowserWindow.

It writes an error into the run-log, if the check fails.

Parameters:
title - Title, which should be checked.
reportName - the Name for the check in the report.
Author:
itcampus
Since:
2.9.1
Package: 'general'

Procedures, which work for any Web component.

Author:
QFS
Since:
3.0
Procedure/DependencyDescription
ProcedureclickAtComponent
Click on a given component, but only if the according parameter is set to true.
ProceduredeleteOverrideComponent
Delete the current association of PriorityWebComponent.
ProceduredoClick
Click on a given component.
ProceduresetOverrideComponent
Set a given component to the PriorityWebComponent.
Procedure: 'clickAtComponent'

Click on a given component, but only if the according parameter is set to true.

Parameters:
client - The name of the SUT client.
id - The Id of the target-component.
click - If this is set to true, the click will be performed, otherwise nothing happens.
Author:
QFS
Since:
3.0
Procedure: 'deleteOverrideComponent'

Delete the current association of PriorityWebComponent.

Parameters:
client - The name of the SUT client.
Author:
QFS
Since:
3.3.0
Procedure: 'doClick'

Click on a given component.

Parameters:
client - The name of the SUT client.
id - The Id of the target-component.
Author:
QFS
Since:
3.0
Procedure: 'setOverrideComponent'

Set a given component to the PriorityWebComponent.

Parameters:
client - The name of the SUT client.
id - The Id of the target-component.
Author:
QFS
Since:
3.3.0
Package: 'input'

Procedures to access INPUT elements.

Author:
QFS
Since:
3.2
Procedure/DependencyDescription
ProcedurefileUpload
Set the value of the INPUT:FILE node by whatever means that are applicable for the browser.
Procedure: 'fileUpload'

Set the value of the INPUT:FILE node by whatever means that are applicable for the browser.

Author:
QFS
Since:
3.2
Package: 'text'

Procedures to access text fields and text areas. It should work with any INPUT:TEXT elements.

Author:
QFS
Since:
3.0
Procedure/DependencyDescription
ProcedureclearArea
Clear a multi-line text area.
ProcedureclearField
Clear a simple text field.
ProceduresetText
Set a given text to a given text-field or text-area.
ProceduresetTextFromFile
Read the content of a given file and set its content to a given text-field.
Procedure: 'clearArea'

Clear a multi-line text area.

Parameters:
client - The name of the SUT client.
id - The id of the text area.
Author:
QFS
Since:
3.0
Procedure: 'clearField'

Clear a simple text field.

Parameters:
client - The name of the SUT client.
id - The id of the text field.
Author:
QFS
Since:
3.0
Procedure: 'setText'

Set a given text to a given text-field or text-area.

If the text is empty, no action will take place.

Parameters:
id - ID of the textfield.
text - text to be set.
append - if this value is set to true, the text will be appended to the current values.
clear - If this value is set to true, the text-field will be cleared in case an empty string is given as parameter "text".
replaySingleEvents - If this value is set to true, the text will be inserted replaying single events.
newline - the separator sign for marking a linebreak within the text
Author:
QFS
Since:
3.0
Procedure: 'setTextFromFile'

Read the content of a given file and set its content to a given text-field.

Parameters:
id - The id of the text-field to set.
file - The path to the file.
Author:
QFS
Since:
3.1.1