GenericMasterFunctions

Last Updated:

Generic actions available for ALL types of Windows and Components.


[How To Read This Reference]
AssignPropertyVariable
Rational Robot Classic Apple IOS Rational RobotJ Mercury Interactive WinRunner Selenium AutomatedQA Test Complete
Assign the string value of an object property to a specific DDVariable
CaptureObjectDataToFile
Rational Robot Classic Rational RobotJ Selenium
Copy the current contents of an object's data to a file.
CapturePropertiesToFile
Rational RobotJ Apple IOS Selenium AutomatedQA Test Complete Android
Copy all of the value properties a test object to a file.
CapturePropertyToFile
Rational RobotJ Apple IOS Selenium AutomatedQA Test Complete
Copy a propertie's value of a test object to to a file.
ClearAppMapCache
Rational RobotJ
Clear the internal application map cache.
GetGUIImage
Android Rational Robot Classic Rational RobotJ Apple IOS SAFS TID Commands Selenium AutomatedQA Test Complete
Capture the screen shot of a GUI component and save it to a file
GetTextFromGUI
Rational RobotJ SAFS TID Commands
Incorporate OCR technology to detect the text on a GUI component and save the text to a variable.
GUIDoesExist
Android Apple IOS Rational Robot Classic Rational RobotJ SAFS TID Commands Mercury Interactive WinRunner Selenium AutomatedQA Test Complete
Routine to verify the visual existence of a particular window and/or component.
GUIDoesNotExist
Android Apple IOS Rational Robot Classic Rational RobotJ SAFS TID Commands Mercury Interactive WinRunner Selenium AutomatedQA Test Complete
Routine to verify the visual non-existence of a particular window and/or component.
HoverMouse
Rational Robot Classic SAFS TID Commands Rational RobotJ AutomatedQA Test Complete
Hover the mouse over an object.
HoverScreenLocation
SAFS TID Commands
Hover the mouse over a specified screen location.
InputCharacters
Rational Robot Classic Android Apple IOS Rational RobotJ SAFS TID Commands Mercury Interactive WinRunner Abbot Commands Selenium
Sends literal text to the specified component.
InputKeys
Rational Robot Classic Rational RobotJ SAFS TID Commands Mercury Interactive WinRunner Abbot Commands Selenium AutomatedQA Test Complete Android
Sends keystrokes to the specified component.
IsPropertyExist
Rational RobotJ AutomatedQA Test Complete
Verify if object's property exists or not.
LocateScreenImage
Rational RobotJ SAFS TID Commands AutomatedQA Test Complete
Store the location and dimensions of a SAFS IBT component or area. Store the location and dimensions of a GUI component (RJ).
SaveTextFromGUI
Rational RobotJ SAFS TID Commands
Incorporate OCR technology to detect the text on a GUI component and save the text to a text file.
SendEvent
Rational RobotJ AutomatedQA Test Complete
Send or trigger an "event" with 0 or more arguments.
SetPropertyValue
Rational Robot Classic Rational RobotJ AutomatedQA Test Complete
Sets a value to the property of an object.
TypeChars
SAFS TID Commands Android
Sends literal text keystrokes to whatever has keyboard focus.
TypeKeys
SAFS TID Commands Android
Sends keystrokes to whatever has keyboard focus.
VerifyArrayPropertyToFile
Rational Robot Classic Rational RobotJ Mercury Interactive WinRunner
Verify the value of an array property with a benchmark file
VerifyBinaryFileToFile
Rational Robot Classic Rational RobotJ SAFS TID Commands AutomatedQA Test Complete
Verify the current contents of a binary file with a benchmark file.
VerifyClipboardToFile
Rational Robot Classic Rational RobotJ Mercury Interactive WinRunner AutomatedQA Test Complete
Verify the current contents of the Windows clipboard with a benchmark file.
VerifyClipboardVP
Rational Robot Classic Mercury Interactive WinRunner
Verify the current contents of the Windows clipboard using a Robot ClipboardVP.
VerifyFileToFile
Rational Robot Classic Rational RobotJ SAFS TID Commands AutomatedQA Test Complete
Verify the current contents of a text file with a benchmark file (same as VerifyTextFileToFile).
VerifyGUIImageToFile
Rational Robot Classic Rational RobotJ Apple IOS SAFS TID Commands Selenium AutomatedQA Test Complete
Verify the screen shot of a GUI component with a benchmark image file
VerifyObjectDataToFile
Rational Robot Classic Rational RobotJ
Verify the current contents of an object's data with a benchmark file.
VerifyPropertiesToFile
Apple IOS Android
Compare/Verify all of the value properties of a test object with a file.
VerifyProperty
Rational Robot Classic Rational RobotJ Apple IOS Mercury Interactive WinRunner Selenium AutomatedQA Test Complete
Verify the value of a single object property
VerifyPropertyContains
Rational Robot Classic Rational RobotJ Apple IOS Mercury Interactive WinRunner Selenium AutomatedQA Test Complete
Verify that the value of an object property contains a string
VerifyPropertyToFile
Rational Robot Classic Apple IOS Rational RobotJ Mercury Interactive WinRunner AutomatedQA Test Complete
Verify the value of a single object property with a benchmark file
VerifyTabOrder
Rational Robot Classic Mercury Interactive WinRunner
Attempts to verify the tab order of the specified object--usually a Window.
VerifyTextFileToFile
Rational Robot Classic Rational RobotJ SAFS TID Commands AutomatedQA Test Complete
Verify the current contents of a text file with a benchmark file (same as VerifyFileToFile).
VerifyValueContains
Rational Robot Classic Rational RobotJ SAFS TID Commands Mercury Interactive WinRunner AutomatedQA Test Complete
Verify that a string value contains a substring
VerifyValues
Rational Robot Classic Rational RobotJ SAFS TID Commands Mercury Interactive WinRunner AutomatedQA Test Complete
Verify that two string values are identical. Note: RobotJ also uses identical keyword 'VerifyValueEquals'
VerifyValuesIgnoreCase
Rational Robot Classic Rational RobotJ SAFS TID Commands Mercury Interactive WinRunner AutomatedQA Test Complete
Verify that two string values are identical, ignoring case.

GenericMasterFunctions::AssignPropertyVariable
Rational Robot Classic Apple IOS Rational RobotJ Mercury Interactive WinRunner Selenium AutomatedQA Test Complete

Assign the string value of an object property to a specific DDVariable

Assign the string value of an object property to a specific DDVariable.
Note, if you supply the name of the variable and include the leading caret (^) symbol then the variable must be enclosed in quotes. Otherwise, that variable will be used like any other variable and the substituted value of that variable will be interpretted as the name of the variable you wish to use.


GenericMasterFunctions::CaptureObjectDataToFile
Rational Robot Classic Rational RobotJ Selenium

Copy the current contents of an object's data to a file.

Only an object that Robot can perform an ObjectData VP on can use this command. By default, the files will be stored in the active "Test" directory. If you specify a relative path, the path will be relative to the project directory. The directory for a full or relative path must already exist.

Fields: [ ]=Optional with Default Value
  1. File
    The name of the file used to store the object data.

    The name of the file used to store the object data. By default, the files will be stored in the active "Test" directory. If you specify a relative path, the path will be relative to the project directory. The directory for a full or relative path must already exist.

  2. [ FileEncoding = ]
    Specify a character encoding to be used when saving data to a file. If it is not specified, the system default file encoding will be used. The encoding should be a valid string supported by Java; if it is not valid, the system default file encoding will be used instead.


  3. [ FilterMode = ]
    (Future) Specify a file filter to use to process the text before comparison.


  4. [ FilterOptions = ]
    (Future) Specify filter options to use with the file filter.


Examples:
  • T, Browser, HTMLTable, CaptureObjectDataToFile, aFilename.ext, , "", ""
    Capture the HTMLTable object data contents to a file.

    Capture the HTMLTable object data contents to the Datapool\Test\aFilename.ext file.
    Note the unused reserved fields for FileFilter and FilterOptions.


  • T, Browser, HTMLTable, CaptureObjectDataToFile, myDirectory\aFilename.ext, , "", ""
    Capture the HTMLTable object data contents to a file.

    Capture the HTMLTable object data contents to the [project]\myDirectory\aFilename.ext file.
    Note the unused reserved fields for FileFilter and FilterOptions.


  • T, Browser, HTMLTable, CaptureObjectDataToFile, tableContent.ext
    Capture the HTMLTable object data contents to a file.

    Capture the HTMLTable object data contents, save it to file tableContent.ext by the system default file encoding.

  • T, Browser, HTMLTable, CaptureObjectDataToFile, tableContent.ext, "UTF-8"
    Capture the HTMLTable object data contents to a file.

    Capture the HTMLTable object data contents, save it to file tableContent.ext by UTF-8 encoding.

[How To Read This Reference]

GenericMasterFunctions::CapturePropertiesToFile
Rational RobotJ Apple IOS Selenium AutomatedQA Test Complete Android

Copy all of the value properties a test object to a file.

Copy all of the value properties a test object to a file. By default, the files will be stored in the active "Test" directory. If you specify a relative path, the path will be relative to the project directory. The directory for a full or relative path must already exist.

GenericMasterFunctions::CapturePropertyToFile
Rational RobotJ Apple IOS Selenium AutomatedQA Test Complete

Copy a propertie's value of a test object to to a file.

Copy a propertie's value of a test object to to a file. The file will be stored in the active "Test" directory. If you specify a relative path, the path will be relative to the project directory. The directory for a full or relative path must already exist.

Fields: [ ]=Optional with Default Value
  1. PropertyName
    The case-sensitive name of the object array property to verify.


  2. File
    The name of the file used to store the property list data.

    The name of the file used to store the property list data. By default, the files will be stored in the active "Test" directory. If you specify a relative path, the path will be relative to the project directory. The directory for a full or relative path must already exist.

  3. [ FileEncoding = ]
    Specify a character encoding to be used when saving data to a file. If it is not specified, the system default file encoding will be used. The encoding should be a valid string supported by Java; if it is not valid, the system default file encoding will be used instead.


Examples:
  • T, Window, Comp, CapturePropertyToFile, propertyName, aFilename.ext
    Capture the value of Comp's property described by propertyName to a file.

    Capture the value of Comp's property described by propertyName to a file.

  • T, Window, Comp, CapturePropertyToFile, propertyName, aFilename.ext
    Capture the value of Comp's property described by propertyName to a file.

    Capture the value of Comp's property described by propertyName, save it to file aFilename.ext by the system default file encoding.

  • T, Window, Comp, CapturePropertyToFile, propertyName, aFilename.ext, "UTF-8"
    Capture the value of Comp's property described by propertyName to a file.

    Capture the value of Comp's property described by propertyName, save it to file aFilename.ext by UTF-8 encoding.

[How To Read This Reference]

GenericMasterFunctions::ClearAppMapCache
Rational RobotJ

Clear the internal application map cache.

Some Engines maintain an internal cache of previously sought application objects. In RobotJ, there exists a cache of TestObject objects, that cache is cleared by this command so that the recognition string algorithm has to be re-run the next time a window or component is to be recognized. This is useful for cases when a dialog pops up, goes away, then pops up again. The cached version of the dialog or it's components may not correspond to the actual version. This command lets a tester clear the cache when this kind of condition may arrise. (Future: instruct the safsmaps service to reload it's application map data)

GenericMasterFunctions::GetGUIImage
Android Rational Robot Classic Rational RobotJ Apple IOS SAFS TID Commands Selenium AutomatedQA Test Complete

Capture the screen shot of a GUI component and save it to a file

Capture the screen shot of a GUI component and save it to a file. The available formats for the output file are BITMAP (*.bmp) and JPEG (*.jpg). For RJ and IBT engine, other formats like TIFF (*.tif), GIF (*.gif), PNG (*.png) and PNM (*.pnm) are also supported. Optionally the user can specify part of the component to capture.

The specified GUI component/part must be in the viewing range of its containing window. If portion of the component is displayed in the window, only that portion will be captured; if the component falls completely out of the viewing range of the window, the command will fail. The command makes no attempt to bring the component into view.

Robot Classic (RC) Specific Notes:
1) This command may fail to execute if the user has turned off logging to TestManager via the Robot tools setting. You may have to enable TestManager logging for the command to successfully execute.
2) This command requires that the TestManager Image Comparator tool is installed on the test machine. Machines having only the Robot Test Agent installed will not be able to use this command.
3) Due to a bug in Robot Classic, images captured using the Robot Classic engine may differ in image size and/or file size from those captured using other supported engines. Depending on the comparator used, rebenching your images may be necessary when migrating to another engine.

RobotJ (RJ) and IBT Specific Notes:
1)It requires that Java Advanced Imaging (JAI) be installed on the test machine
2)It supports to save image in format TIFF (*.tif), GIF (*.gif), PNG (*.png) and PNM (*.pnm)

Apple IOS specific Notes:
UIAutomation captures all screenshots as PNG images, but SAFS copies and stores them into the image format desired (JPG, BMP, etc.). However, the rootname of the desired output image name must be unique to avoid UIAutomation generating indexed image names we will not be looking for.
For example, specifying MyImage.JPG and later MyImage.BMP will cause UIAutomation to capture MyImage.PNG and MyImage1.PNG. When attempting to find MyImage.PNG captured for MyImage.BMP we will retrieve MyImage.PNG which is NOT the correct image capture for MyImage.BMP.



Fields: [ ]=Optional with Default Value
  1. OutputFile
    Path (with filename) to the output image file.

    Path/file name of the output image file. This can be a full path, a relative path or just a file name. If relative, it is appended to the Datapool directory; if only a file name without path, the file will be saved in Datapool\Test directory. The extension of the file must be either .bmp or .jpg. If not, .bmp is appended to this parameter to force a BITMAP export.

  2. [ SubArea = ]
    Optional app map subkey indicating partial image of the component to capture.

    Optional app map subkey indicating partial image of the component to capture. Value of this app map reference must be in the format of a top-left and bottom-right pair, and can be either absolute coordinates or percentages ("x1,y1,x2,y2" or "x1%,y1%,x2%,y2%"). Coordinates are relative to the component, i.e. (0,0) and (0%,0%) are the minimum, and (COMPONENT_WIDTH, COMPONENT_HEIGHT) and (100%,100%) are the maximum. Values exceeding the minimun/ maximum are forced to the nearest limiting value. Absolute and percent values can be mixed, so "0,0,50%,50%" is valid. If this parameter is omitted, full image of the component is captured (equivalent to "0,0,100%,100%").

Examples:
  • T, WINDOW, COMPONENT, GetGUIImage, "C:\comp.bmp"
    Save the full component image to BITMAP file "C:\comp.bmp".


  • T, WINDOW, COMPONENT, GetGUIImage, "Datapool\comp.jpg"
    Save the full component image to JPEG file "<project>\Datapool\comp.jpg".


  • T, WINDOW, COMPONENT, GetGUIImage, "Datapool\Logs\comp.bmp", SUBAREA
    Save specified part of the component image.

    Save specified part of the component image. Depending on the definition of SUBAREA in the app map, the command captures: UNDER [COMPONENT] IN APP MAP PART OF COMPONENT ---------------------------- --------------------- SUBAREA="0,0,10,10" top-left 10x10 square SUBAREA="0,80%,100%,100%" bottom fifth

[How To Read This Reference]

GenericMasterFunctions::GetTextFromGUI
Rational RobotJ SAFS TID Commands

Incorporate OCR technology to detect the text on a GUI component and save the text to a variable.

Two open-source OCRs are integrated into SAFS. One is TesseractOCR (TOCR) at http://code.google.com/p/tesseract-ocr; the other GOCR at http://jocr.sourceforge.net.

TOCR 2.0.4 and GOCR 0.48 are the latest release. They are available in SAFS and only support English. Both two OCR owners claim to support more languages in next release. Chinese, Japanese, and Korean are going to be supported in TOCR's next release 3.00.



Fields: [ ]=Optional with Default Value
  1. VariableName
    The name of the variable to receive detected text.

    The name of the variable to receive detected text. Note, if you supply the name of the variable and include the leading caret (^) symbol then the variable must be enclosed in quotes. Otherwise, that variable will be used like any other variable and the substituted value of that variable will be interpreted as the name of the variable you wish to use.

  2. [ SubArea = ]
    Optional app map subkey indicating partial image of the component to capture.

    Optional app map subkey indicating partial image of the component to capture. Value of this app map reference must be in the format of a top-left and bottom-right pair, and can be either absolute coordinates or percentages ("x1,y1,x2,y2" or "x1%,y1%,x2%,y2%"). Coordinates are relative to the component, i.e. (0,0) and (0%,0%) are the minimum, and (COMPONENT_WIDTH, COMPONENT_HEIGHT) and (100%,100%) are the maximum. Values exceeding the minimun/ maximum are forced to the nearest limiting value. Absolute and percent values can be mixed, so "0,0,50%,50%" is valid.

    If this parameter is omitted with blank or empty string, full image of the component is captured (equivalent to "0,0,100%,100%").



  3. [ OCRId = ]
    OCRId indicating the OCR used to recognize text.

    Two OCR engines are supported. "TOCR" will be taken as default if the parameter is blank. "TOCR" stands for Tesseract OCR; "GOCR" stands for GOCR.

    Note: Seems TOCR performs a bit better than GOCR (personal experience).



  4. [ LangId = ]
    Optional LangId representing the language in use for selected OCR to recognize text.

    For both TOCR and GOCR, only English is supported so far. Language Id takes standard language code, which can be gotten by calling Locale.ENGLISH.getLanguage().

    				LangId      Language
    				"en"   ---  English
    				"cn"   ---  Chinese
    			 

    If LangId is not specified with blank or empty string, the language of System locale will be used as default.



  5. [ ScaleRatio = ]
    Optional ScaleRatio indicating the scale ratio for resizing the original image.

    To fit in font size and DPI required by OCR, SAFS needs to resize images before sending them to OCR engines. For screen-captured images with 96DPI, TOCR takes 1.9 as default; GOCR takes 1.5 as default. You may try different ScaleRatio to find an appropriate value if default setting is unable to meet your requirement.

Examples:
  • T, Window, Comp, GetTextFromGUI, Var1, , GOCR, en,
    Detect the text in the full image of Comp using GOCR with English and default ScaleRatio(1.5), then save it to variable Var1.



[How To Read This Reference]

GenericMasterFunctions::GUIDoesExist
Android Apple IOS Rational Robot Classic Rational RobotJ SAFS TID Commands Mercury Interactive WinRunner Selenium AutomatedQA Test Complete

Routine to verify the visual existence of a particular window and/or component.

Routine to verify the visual existence of a particular window and/or component.
If the window(Field 2) and component(Field 3) are the same then we only check for the existence of the window. However, if the component is actually a child of the window then we first check for the window and then check for the component.

If a Window or Component is HIDDEN, it will be treated as if it Does NOT Exist. The item must be VISIBLE to pass.



GenericMasterFunctions::GUIDoesNotExist
Android Apple IOS Rational Robot Classic Rational RobotJ SAFS TID Commands Mercury Interactive WinRunner Selenium AutomatedQA Test Complete

Routine to verify the visual non-existence of a particular window and/or component.

Routine to verify the visual non-existence of a particular window and/or component.
If the window(Field 2) and component(Field 3) are the same then we only check for the visual non-existence of the window. However, if the component is actually a child of the window then we first check for the visual existence of the window and then check for the visual non-existence of the component.

If a Window or Component is HIDDEN, it will be treated as if it Does NOT Exist. The item must not exist or be HIDDEN to pass.



GenericMasterFunctions::HoverMouse
Rational Robot Classic SAFS TID Commands Rational RobotJ AutomatedQA Test Complete

Hover the mouse over an object.

By default, hover on the center of the component for 2000 milliseconds.

We can also hover on any part of an object based on a stored x,y coordinate. The object containing the coordinate is first given context and then the hover command is generated at the coordinate. Thus, an item or object can be referenced by name even though it is only recognized via coordinates.

The coordinate lookup is done with the component name of the record AND Field #5.

Typical Data Table records:

(1) t MainWindow Component HoverMouse 1000
(2) t MainWindow MainWindow HoverMouse AnObject 2000
(3) t MainWindow FolderTree HoverMouse Node1 3000

#1 above will contain a blank as it's 5th field and 1000 as 6th field, and it will hover at the center of the Component for 1000 milliseconds.

#2 above will contain an AnObject="3,10" entry in the MainWindow section of the Application Map to hover at x=3, y=10 in the MainWindow.

#3 above will contain a FolderTree entry in the MainWindow section with normal recognition information for it. FolderTree will also have it's own section in the Application Map in which there will be an entry like Node1="15,30". This will tell Robot to locate the FolderTree Generic object and hover at the coordinates specified by the reference.

Robot Classic (RC) Specific Notes:
1) This command requires a version of Rational Robot that includes MousePause support (released and patched in Robot v2003). Though not required, you may also choose to enable this functionality for Robot Recording (Tools->GUI Record Options...->General Tab).

Test Complete (TC) Specific Notes:
The optional parameter HoverTime doesn't take effect, so don't supply it.



Fields: [ ]=Optional with Default Value
  1. [ AppMapSubkey = ]
    (Optional)Name of the AppMap subkey to lookup and use for the hover.

    Without this we should hover on the center of the object.

    Name of the AppMap subkey to lookup and use for the hover. We expect the AppMap to contain the item in the format "x,y":

    [Component]
    Node1="33,120" OR
    Node1="Coords=33,120" OR
    Node1="Icon" (or whatever is appropriate)

    The results from the lookup are appended to the "Coords=" string used by the hover command in Robot (if necessary). So any valid content used with the hover command can be part of this AppMap entry.

    Both Fields #3 and #5 are used to locate the item in the App Map. This routine does not specify an App Map so only the current Map is used and it is expected to be valid.



  2. [ HoverTime = 2000 ]
    (Optional)Number of milliseconds to hover.

    If not specified, the mouse will hover for 2000 milliseconds over the object,

Examples:
  • T, WINDOW, WINDOW, HoverMouse
    Hover the mouse over the center of WINDOW for 2000 milliseconds.

    Hover the mouse over the center of WINDOW for 2000 milliseconds.

  • T, WINDOW, AnObject, HoverMouse, "Coords=200,400"
    Hover the mouse over coordinates 200,400 of AnObject for 2000 milliseconds.

    Hover the mouse over coordinates 200,400 of AnObject for 2000 milliseconds.

  • T, WINDOW, AnObject, HoverMouse, ASubObject, 1000
    Hover the mouse over an x,y coordinate indicated by the ASubObject reference in the Application Map for 1000 milliseconds.

    Field 5 : TQ String. A reference identified in the Application Map identifying coordinates on which to hover. This example shows AnObject as a viable object in the WINDOW but that it also has its own section in the Application Map which contains one or more named references like ASubObject which are used for test.

  • T, WINDOW, AnObject, HoverMouse, , 3000
    Hover the mouse over the center of AnObject for 3000 milliseconds.

    Hover the mouse over the center of AnObject for 3000 milliseconds.

[How To Read This Reference]

GenericMasterFunctions::HoverScreenLocation
SAFS TID Commands

Hover the mouse over a specified screen location.

Hover the mouse over a specified screen location.

We can hover on any screen location based on stored x,y coordinates or hardcoded literal values. The Window:Component fields can be anything at all and will be ignored if they do not exist in the app map, or if the retrieved app map data does not contain coordinate data. Thus, an item or object can be referenced by name even though it is only known via coordinates.

If the Window:Component AppMap lookup does NOT contain coordinate data and is ignored, then the AppMapSubKey field is REQUIRED and is expected to contain a reference or literal text containing absolute screen coordinates.

If the Window:Component AppMap lookup DOES contain coordinate data, this data is treated as the absolute screen coordinates to be used. The AppMapSubKey field becomes OPTIONAL and coordinate data in the field is treated as a relative offset added to the absolute values found for the Window:Component.

Any AppMapSubKey lookup is done with the Component name in the record AND Field #5.

Typical Data Table records:

(1) t MainWindow Component HoverScreenLocation 1000
(2) t MainWindow MainWindow HoverScreenLocation AnObject 2000
(3) t MainWindow MainWindow HoverScreenLocation 50,80 3000
(4) t AnyWin AnyComp HoverScreenLocation Node1 3000

#1 above will contain a blank as it's 5th field and 1000 as 6th field. Because the AppMapSubKey field is blank, the [MainWindow] section of the AppMap MUST have a Component item with valid absolute screen coordinate data. The mouse cursor will hover at the specified Component location for 1000 milliseconds.

#2 above will contain an AnObject="Coords=50,80" entry in the [MainWindow] section of the AppMap. If there is a MainWindow component in the AppMap with valid screen coordinates then the mouse cursor will hover with a relative offset of 50,80 from those absolute screen coordinates. Otherwise, the mouse will hover at absolute screen coordinates 50,80.

#3 If there is a MainWindow component in the [MainWindow] section of the AppMap with valid screen coordinates then the mouse cursor will hover with a relative offset of 50,80 from those absolute screen coordinates. Otherwise, the mouse will hover at absolute screen coordinates 50,80.

#4 above will contain no valid AnyWin:AnyComp coordinate data and those fields will be ignored. However, Node1 MUST exist in the Application Map [AnyComp] section to provide absolute screen coordinates.



Fields: [ ]=Optional with Default Value
  1. [ AppMapSubkey = ]
    (Sometimes Optional)Name of the AppMap subkey to lookup and use for the hover.

    Without this there MUST be absolute screen coordinates stored in the AppMap for the Window:Component specified.

    Name of the AppMap subkey to lookup and use for the hover. We expect the AppMap to contain the coordinates in the following supported formats:

                    [Component]
                    Node1="33,120"        (comma-delimited)      OR
                    Node1="33;120"        (semi-colon delimited) OR
                    Node1="33 120"        (space-delimited)      OR
                    Node1="Coords=33,120" (comma-delimited)      OR
                    Node1="Coords=33;120" (semi-colon delimited) OR
                    Node1="Coords=33 120" (space-delimited)
                    

    Both Fields #3 and #5 are used to locate the item in the App Map. This routine does not specify an App Map so only the current Map is used and it is expected to be valid.

    This field can instead contain the literal text of any absolute or relative coordinates in the same formats as shown above.



  2. [ HoverTime = 2000 ]
    (Optional)Number of milliseconds to hover.

    If not specified, the mouse will hover at the specified coordinates for 2000 milliseconds.

Examples:
  • T, WINDOW, WINDOW, HoverScreenLocation
    Hover the mouse at specified WINDOW coordinates for 2000 milliseconds.

    Hover the mouse at screen coordinates specified for the Window item stored in the [Window] section of the current AppMap.

  • T, WINDOW, AnObject, HoverScreenLocation, "Coords=200,400"
    Hover the mouse at coordinates 200,400 for 2000 milliseconds.

    Hover the mouse at coordinates 200,400 for 2000 milliseconds. This assumes AnObject is NOT an item in the [Window] section of the current AppMap with valid coordinate data.

  • T, WINDOW, AnObject, HoverScreenLocation, ASubObject, 1000
    Hover the mouse using x,y screen coordinates stored in the ASubObject reference in the [AnObject] section of the current AppMap for 1000 milliseconds.

    ASubObject reference found in the AppMap [AnObject] section stores screen coordinates on which to hover.

  • T, WINDOW, AnObject, HoverScreenLocation, , 3000
    Hover the mouse over the Window:AnObject screen coordinates for 3000 milliseconds.

    Because no AppMapSubKey is provided the AnObject item MUST exist in the [WINDOW] section of the current AppMap and it MUST contain valid screen coordinate data.

[How To Read This Reference]

GenericMasterFunctions::InputCharacters
Rational Robot Classic Android Apple IOS Rational RobotJ SAFS TID Commands Mercury Interactive WinRunner Abbot Commands Selenium

Sends literal text to the specified component.

Sends literal text to the specified component. The InputChars command does not convert or interpret any special characters like InputKeys (InputKeystrokes) does.

Some engines cannot set keyboard focus to the component. These engines will require the component already have keyboard focus before calling this command.



GenericMasterFunctions::InputKeys
Rational Robot Classic Rational RobotJ SAFS TID Commands Mercury Interactive WinRunner Abbot Commands Selenium AutomatedQA Test Complete Android

Sends keystrokes to the specified component.

Sends keystrokes to the specified component.

Some engines cannot set keyboard focus to the component. These engines will require the component already have keyboard focus before calling this command.



Fields: [ ]=Optional with Default Value
  1. TextValue
    String of keystrokes to send.


Examples:
  • T, WINDOW, COMPONENT, INPUTKEYS, "Some Text to Input"
    This action sends "Some Text to Input" as keystrokes to the COMPONENT object.

    Field 5 : TQ String. case-sensitive text to send to the specified component.

    Some Special Characters:
                    {Enter}= ENTER key
                    {Tab} = TAB key
                    ^ = CONTROL Key with another key ( "^S" = CONTROL + s)
                    %= ALT  Key with another key ("%F" = ALT + F)
                    + = SHIFT key with another key ("+{Enter}" = SHIFT + ENTER)
                    

    Currently, we pass-thru to the underlying implementation (Rational SQABasic). Any future implementations will also use the same syntax. Note: Only valid for components that accept windows keyboard input

    Important Abbot note. Presently, no special character handling is in place. If using the Abbot engine the keys will be sent litterally without interpretation. For example, {TAB} would be sent as those exact characters NOT the tab key.



[How To Read This Reference]

GenericMasterFunctions::IsPropertyExist
Rational RobotJ AutomatedQA Test Complete

Verify if object's property exists or not.


GenericMasterFunctions::LocateScreenImage
Rational RobotJ SAFS TID Commands AutomatedQA Test Complete

Store the location and dimensions of a SAFS IBT component or area. Store the location and dimensions of a GUI component (RJ).

Store the location and dimensions of a SAFS IBT component or area.
Store the location and dimensions of a GUI component (RJ). The information is stored in a collection of variables using the variable root name provided.

The following variables are set by this command:

    rootname=x y w h [space delimited values]
    rootname.x=x
    rootname.y=y
    rootname.w=w
    rootname.h=h

Currently in IBT, all coordinates are relative to the screen and not to any parent window location or other client area.



Fields: [ ]=Optional with Default Value
  1. VariableName
    The root name of the collection of variables to receive the location and dimensions.


  2. [ WhomRelativeTo = screen ]
    This parameter decides the coordinates stored in VariableName is relative to the screen or the parent window. 'screen' means they are relative to the screen; 'parent' means they are relative to the parent window. The parameter is curently available in RJ only.


Examples:
  • T, WindowID, WindowID, LocateScreenImage, AVariableName
    Stores the following variable values:

      AVariableName=x y w h [space delimited values]
      AVariableName.x=x
      AVariableName.y=y
      AVariableName.w=w
      AVariableName.h=h



  • C, SetVariableValues, ^AVariableName="NextVariableName"
    T, WindowID, WindowID, LocateScreenImage, ^AVariableName

    Stores the following variable values:

      NextVariableName=x y w h [space delimited values]
      NextVariableName.x=x
      NextVariableName.y=y
      NextVariableName.w=w
      NextVariableName.h=h



  • T, ParentWindow, Component, LocateScreenImage, AVariableName, parent
    AVariableName stores the coordinates that are relative to the left-top point of the ParentWindow:

      AVariableName=x y w h [space delimited values]
      AVariableName.x=x
      AVariableName.y=y
      AVariableName.w=w
      AVariableName.h=h



[How To Read This Reference]

GenericMasterFunctions::SaveTextFromGUI
Rational RobotJ SAFS TID Commands

Incorporate OCR technology to detect the text on a GUI component and save the text to a text file.

Two open-source OCRs are integrated into SAFS. One is TesseractOCR (TOCR) at http://code.google.com/p/tesseract-ocr; the other GOCR at http://jocr.sourceforge.net.

TOCR 2.0.4 and GOCR 0.48 are the latest release. They are available in SAFS and only support English. Both two OCR owners claim to support more languages in next release. Chinese, Japanese, and Korean are going to be supported in TOCR's next release 3.00.



Fields: [ ]=Optional with Default Value
  1. OutputFile
    The name of the text file used to store detected text.

    The name of the text file used to store detected text. By default, the files will be stored in the active "Test" directory. If you specify a relative path, the path will be relative to the project directory. The directory for a full or relative path must already exist.

  2. [ SubArea = ]
    Optional app map subkey indicating partial image of the component to capture.

    Optional app map subkey indicating partial image of the component to capture. Value of this app map reference must be in the format of a top-left and bottom-right pair, and can be either absolute coordinates or percentages ("x1,y1,x2,y2" or "x1%,y1%,x2%,y2%"). Coordinates are relative to the component, i.e. (0,0) and (0%,0%) are the minimum, and (COMPONENT_WIDTH, COMPONENT_HEIGHT) and (100%,100%) are the maximum. Values exceeding the minimun/ maximum are forced to the nearest limiting value. Absolute and percent values can be mixed, so "0,0,50%,50%" is valid.

    If this parameter is omitted with blank or empty string, full image of the component is captured (equivalent to "0,0,100%,100%").



  3. [ OCRId = ]
    OCRId indicating the OCR used to recognize text.

    Two OCR engines are supported. "TOCR" will be taken as default if the parameter is blank. "TOCR" stands for Tesseract OCR; "GOCR" stands for GOCR.

    Note: Seems TOCR performs a bit better than GOCR (personal experience).



  4. [ LangId = ]
    Optional LangId representing the language in use for selected OCR to recognize text.

    For both TOCR and GOCR, only English is supported so far. Language Id takes standard language code, which can be gotten by calling Locale.ENGLISH.getLanguage().

    				LangId      Language
    				"en"   ---  English
    				"cn"   ---  Chinese
    			 

    If LangId is not specified with blank or empty string, the language of System locale will be used as default.



  5. [ ScaleRatio = ]
    Optional ScaleRatio indicating the scale ratio for resizing the original image.

    To fit in font size and DPI required by OCR, SAFS needs to resize images before sending them to OCR engines. For screen-captured images with 96DPI, TOCR takes 1.9 as default; GOCR takes 1.5 as default. You may try different ScaleRatio to find an appropriate value if default setting is unable to meet your requirement.

Examples:
  • T, Window, Comp, SaveTextFromGUI, ocr.txt, , TOCR, en, 2.0
    Detect the text in the full image of Comp using TOCR with English and ScaleRatio 2.0, then save the text to [project]\Datapool\test\ocr.txt.



[How To Read This Reference]

GenericMasterFunctions::SendEvent
Rational RobotJ AutomatedQA Test Complete

Send or trigger an "event" with 0 or more arguments.

For objects or technologies that can be effectively event-driven, rather than GUI-driven.

The first implementation is in IBM Rational Functional Tester for Flex testing. Many Flex objects respond to events, in addition to traditional GUI interaction. Some Flex objects ONLY respond to events. This is especially true of many custom Flex delegates.

The tester must know the events and arguments available for their particular object and technology. The generic nature for this command cannot generally know if a particular event or set of arguments is valid or not. Thus, the implementation may not be able issue failures resulting from invalid events, arguments, or other issues not generating recognizable failure conditions.



GenericMasterFunctions::SetPropertyValue
Rational Robot Classic Rational RobotJ AutomatedQA Test Complete

Sets a value to the property of an object.

Routine to set a value to the property of an object.

.

The routine expects that the given object already has Context or Focus. It also expects that Global StepDriverTestInfo contains all the information it needs to perform its function.

The routine will set the StepDriverTestInfo.statuscode and log any pass/fail info using the StepDriverTestInfo.fac LogFacility.

RJ implementation directly modifies the object in the software under test;therefore, it should be done with extreme care. Avoid using setPropertyValue whenever possible because it allows you to modify the software under test in ways that a typical user cannot.



GenericMasterFunctions::TypeChars
SAFS TID Commands Android

Sends literal text keystrokes to whatever has keyboard focus.

Sends literal text keystrokes to whatever has keyboard focus. The TypeChars command does not convert or interpret any special characters like InputKeys or TypeKeys do.

No attempt is made to locate any specific window or component. Keystrokes are simply sent to the system.



GenericMasterFunctions::TypeKeys
SAFS TID Commands Android

Sends keystrokes to whatever has keyboard focus.

Sends keystrokes to whatever has keyboard focus.

No attempt is made to locate any specific window or component. Keystrokes are simply sent to the system.



Fields: [ ]=Optional with Default Value
  1. TextValue
    String of keystrokes to send.


Examples:
  • T, Anything, At All, TYPEKEYS, "%F{ENTER}"
    This action sends "ALT + F" then the ENTER key to the system.

    Field 5 : TQ String. case-sensitive text to send.

    Some Special Characters:
                    {Enter}= ENTER key
                    {Tab} = TAB key
                    ^ = CONTROL Key with another key ( "^S" = CONTROL + s)
                    %= ALT  Key with another key ("%F" = ALT + F)
                    + = SHIFT key with another key ("+{Enter}" = SHIFT + ENTER)
                    



[How To Read This Reference]

GenericMasterFunctions::VerifyArrayPropertyToFile
Rational Robot Classic Rational RobotJ Mercury Interactive WinRunner

Verify the value of an array property with a benchmark file

Typically, benchmarks are stored in the Datapool\Bench directory. In that event, only the filename.ext is needed. There is currently a limit of 32K allowed for this type of comparison.

The command will produce a TEST WARNING if the user has configured an alternate DIFF tool for which we have no means to compare the diff results. If this WARNING is expected, the user should use the "TW" test record type.

Note: for RobotJ,Suggest to use RFT Inspector to confirm which property should be used. There are two examples:

  1. For Java swing List and ComboBox items can be fetchedusing the '.itemText' property (Note the dot)
  2. For Html List (type is html.select) items can be fetchedusing the '.text' property (Note the dot)



GenericMasterFunctions::VerifyBinaryFileToFile
Rational Robot Classic Rational RobotJ SAFS TID Commands AutomatedQA Test Complete

Verify the current contents of a binary file with a benchmark file.

Verify the current contents of a binary file with a benchmark file.
Typically, benchmarks are stored in the Datapool\Bench directory. Typically, files to test are stored in the Datapool\Test directory. In that event, the filename.ext is needed for both files.
The Window and Component objects are not validated and have no role. The Window and Component strings can be any text, but they cannot be blank.

The command may produce a WARNING if a diff tool for which we have no means to verify the results is configured for use. Consequently, if these warnings are expected, the user can use the "TW" test record type to avoid issuing these warnings.



Fields: [ ]=Optional with Default Value
  1. BenchmarkFile
    File used as the comparison benchmark.

    File used as the comparison benchmark.
    This can be a full path, a relative path, or a file name. If it is a filename, it is expected to be in the project's Datapool\Bench directory. If it is a relative path, FindSQAFile is used to located the file.


  2. ActualFile
    File used as the comparison file under test.

    File used as the comparison file under test.
    This can be a full path, a relative path, or a file name. If it is a relative path or a file name, the command will try to find the file in the project's Datapool\Test directory.


  3. [ FilterMode = ]
    (Future) Specify a file filter to use to process the text before comparison.


  4. [ FilterOptions = ]
    (Future) Specify filter options to use with the file filter.


Examples:
  • T, Browser, HTMLTable, VerifyBinaryFileToFile, bFilename.ext, aFilename.ext, "", ""
    Verify a test binary file with the benchmark file.

    Verify the test binary file with the benchmark file. The benchmark file is located within the Project at Datapool\Bench\bFilename.ext
    The test file is located within the Project at Datapool\Test\aFilename.ext
    Note the unused reserved fields for FileFilter and FilterOptions.


  • T, Anything, AtAll, VerifyBinaryFileToFile, c:\Dir\bFilename.ext, c:\Dir\aFilename.ext
    Verify a test text file with the benchmark file.

    Verify the test text file with the benchmark file.
    The benchmark file is not located within the Project. It is at c:\Dir\bFilename.ext The test file is not located within the Project. It is at c:\Dir\aFilename.ext


[How To Read This Reference]

GenericMasterFunctions::VerifyClipboardToFile
Rational Robot Classic Rational RobotJ Mercury Interactive WinRunner AutomatedQA Test Complete

Verify the current contents of the Windows clipboard with a benchmark file.

Verify the current contents of the Windows clipboard with a benchmark file.
Typically, benchmarks are stored in the Datapool\Bench directory. In that event, only the filename.ext is needed. There is currently a limit of 32K allowed for this type of comparison.
The Window and Component objects are not validated and have no role. The Window and Component strings can be any text, but they cannot be blank.

The command will produce a TEST WARNING if the user has configured an alternate DIFF tool for which we have no means to compare the diff results. If this WARNING is expected, the user should use the "TW" test record type.



GenericMasterFunctions::VerifyClipboardVP
Rational Robot Classic Mercury Interactive WinRunner

Verify the current contents of the Windows clipboard using a Robot ClipboardVP.

Verify the current contents of the Windows clipboard using a Robot ClipboardVP.
The benchmark VP must already exist as an asset of the currently running script.

If the provided VP is NOT a reference in the AppMap then a standard VP compare will occur with the typical VP parameter value like "VP=StoredVP".
However, if you wish to modify the ClipboardVP parameter values, such as specifying that the expected result = FAIL, then you must make an entry in the AppMap under the Component name to provide these modified parameters.

The Window and Component objects are not validated and normally have no role. The Window and Component strings can normally be any text, but they cannot be blank.
However, the Component must be a valid section in the AppMap if we wish to store modified VP parameter settings.



Fields: [ ]=Optional with Default Value
  1. VPName
    The name of the ClipboardVP from the currently running script.


Examples:
  • T, Nonsense, NonsenseToo, VerifyClipboardVP, ClipboardContentsVP
    Verify the current contents of the Windows clipboard using the stored Robot ClipboardVP "ClipboardContentsVP".

    Verify the current contents of the Windows clipboard using the stored Robot ClipboardVP "ClipboardContentsVP".
    No AppMap references for the ClipboardContentsVP performs a normal comparison.


  • T, Browser, Browser, VerifyClipboardVP, BrowserContentsVP
    Verify the current contents of the Windows clipboard using the stored Robot ClipboardVP "BrowserContentsVP".

    Verify the current contents of the Windows clipboard using the stored Robot ClipboardVP "BrowserContentsVP".
    If "BrowserContentsVP" is NOT in the AppMap then a VP compare will occur with the typical VP parameter value like VP=BrowserContentsVP.

    However, if you wish to modify the ClipboardVP parameter values, such as specifying that the expected result = FAIL, then you must make an entry in the AppMap under the Component name to add these modified parameters.

    AppMap Example for Example #1: [Browser] Browser=Type=Window.... ... BrowserContentsVP=ExpectedResult=FAIL;Wait=1,5


  • T, Browser, HTMLTable, VerifyClipboardVP, TableContentsVP
    Verify the current contents of the Windows clipboard using the stored Robot ClipboardVP "TableContentsVP".

    Verify the current contents of the Windows clipboard using the stored Robot ClipboardVP "TableContentsVP".
    If "TableContentsVP" is NOT in the AppMap then a VP compare will occur with the typical VP parameter value like VP=TableContentsVP.

    However, if you wish to modify the ClipboardVP parameter values, such as specifying that the expected result = FAIL, then you must make an entry in the AppMap under the Component name to add these modified parameters.

    AppMap Example for Example #2: [Browser] Browser=Type=Window.... HTMLTable=Type=HTMLTable.... [HTMLTable] TableContentsVP=ExpectedResult=FAIL;Wait=1,5


[How To Read This Reference]

GenericMasterFunctions::VerifyFileToFile
Rational Robot Classic Rational RobotJ SAFS TID Commands AutomatedQA Test Complete

Verify the current contents of a text file with a benchmark file (same as VerifyTextFileToFile).

Verify the current contents of a text file with a benchmark file (same as VerifyTextFileToFile).
Typically, benchmarks are stored in the Datapool\Bench directory. Typically, files to test are stored in the Datapool\Test directory. In that event, the filename.ext is needed for both files.
The Window and Component objects are not validated and have no role. The Window and Component strings can be any text, but they cannot be blank.

The command may produce a WARNING if a diff tool for which we have no means to verify the results is configured for use. Consequently, if these warnings are expected, the user can use the "TW" test record type to avoid issuing these warnings.



Fields: [ ]=Optional with Default Value
  1. BenchmarkFile
    File used as the comparison benchmark.

    File used as the comparison benchmark.
    This can be a full path, a relative path, or a file name. If it is a filename, it is expected to be in the project's Datapool\Bench directory. If it is a relative path, FindSQAFile is used to located the file.


  2. ActualFile
    File used as the comparison file under test.

    File used as the comparison file under test.
    This can be a full path, a relative path, or a file name. If it is a relative path or a file name, the command will try to find the file in the project's Datapool\Test directory.


  3. [ FilterMode = ]
    (Future) Specify a file filter to use to process the text before comparison.


  4. [ FilterOptions = ]
    (Future) Specify filter options to use with the file filter.


Examples:
  • T, Browser, HTMLTable, VerifyFileToFile, bFilename.ext, aFilename.ext, "", ""
    Verify a test text file with the benchmark file (same as VerifyTextFileToFile).

    Verify the test text file with the benchmark file (same as VerifyTextFileToFile). The benchmark file is located within the Project at Datapool\Bench\bFilename.ext
    The test file is located within the Project at Datapool\Test\aFilename.ext
    Note the unused reserved fields for FileFilter and FilterOptions.


  • T, Anything, AtAll, VerifyFileToFile, c:\Dir\bFilename.ext, c:\Dir\aFilename.ext
    Verify a test text file with the benchmark file (same as VerifyTextFileToFile).

    Verify the test text file with the benchmark file (same as VerifyTextFileToFile).
    The benchmark file is not located within the Project. It is at c:\Dir\bFilename.ext The test file is not located within the Project. It is at c:\Dir\aFilename.ext


[How To Read This Reference]

GenericMasterFunctions::VerifyGUIImageToFile
Rational Robot Classic Rational RobotJ Apple IOS SAFS TID Commands Selenium AutomatedQA Test Complete

Verify the screen shot of a GUI component with a benchmark image file

Verify the screen shot of a GUI component with a benchmark image file.
The benchmark file must reside in the <project>\Datapool\Bench folder. Only BMP and JPG files can be used as the benchmark. If the extension of the bench file is not BMP or JPG, it is considered a BMP file. For RJ and IBT engine, other formats like TIFF (*.tif), GIF (*.gif), PNG (*.png) and PNM (*.pnm) are also supported. Optionally the user can specify part of the component to verify.
The specified GUI component/part must be in the viewing range of its containing window. If portion of the component is displayed in the window, only that portion will be captured; if the component falls completely out of the viewing range of the window, the command will fail. The command makes no attemp to bring the component into view.

NOTE: the command may fail to execute if the user has turned off logging to TestManager via the Robot tools setting. You may have to enable TestManager logging for the command to successfully execute.

The command may produce a WARNING if a diff tool for which we have no means to verify the results is configured for use. Consequently, if these warnings are expected, the user can use the "TW" test record type to avoid issuing these warnings.

This command requires that TestManager Image Comparator tool is installed on the machine. Machines having only the Robot Test Agent installed will not be able to usee this command.

RobotJ (RJ) and IBT Specific Notes:
1)It requires that Java Advanced Imaging (JAI) be installed on the test machine
2)It supports to save image in format TIFF (*.tif), GIF (*.gif), PNG (*.png) and PNM (*.pnm)

Apple IOS specific Notes:
UIAutomation captures all screenshots as PNG images, but SAFS copies and stores them into the image format desired (JPG, BMP, etc.). However, the rootname of the desired output image name must be unique to avoid UIAutomation generating indexed image names we will not be looking for.
For example, specifying MyImage.JPG and later MyImage.BMP will cause UIAutomation to capture MyImage.PNG and MyImage1.PNG. When attempting to find MyImage.PNG captured for MyImage.BMP we will retrieve MyImage.PNG which is NOT the correct image capture for MyImage.BMP.



Fields: [ ]=Optional with Default Value
  1. BenchmarkFile
    Name of the benchmark image file.

    Name of the benchmark image file. Relative paths suitable for FindSQAFile can be used. Normally, the Benchmark file would reside in the Project's Datapool\Bench directory. A test file with the same name would be created in the Datapool\Test folder. The resulting dif file with .txt extension would be saved under the Datapool\Dif folder. The extension of the benchmark file should be .bmp or .jpg. If not, it is considered a BMP file, i.e. the test file would have a .bmp extension.

  2. [ SubArea = ]
    Optional app map subkey indicating partial image of the component to verify.

    Optional app map subkey indicating partial image of the component to verify. Value of this app map reference must be in the format of a top-left and bottom-right pair, and can be either absolute coordinates or percentages ("x1,y1,x2,y2" or "x1%,y1%,x2%,y2%"). Coordinates are relative to the component, i.e. (0,0) and (0%,0%) are the minimum, and (COMPONENT_WIDTH, COMPONENT_HEIGHT) and (100%,100%) are the maximum. Values exceeding the minimun/ maximum are forced to the nearest limiting value. Absolute and percent values can be mixed, so "0,0,50%,50%" is valid. If this parameter is omitted, full image of the component is captured (equivalent to "0,0,100%,100%").

Examples:
  • T, WINDOW, COMPONENT, VerifyGUIImageToFile, "comp.bmp"
    Verify the full component image with BITMAP file "<project>\Datapool\Bench\comp.bmp".


  • T, WINDOW, COMPONENT, VerifyGUIImageToFile, "comp.jpg"
    Verify the full component image with JPEG file "<project>\Datapool\Bench\comp.jpg"


  • T, WINDOW, COMPONENT, VerifyGUIImageToFile, "comp.bmp", SUBAREA
    Verify specified part of the component image with a bench file.

    Verify specified part of the component image with a bench file Depending on the definition of SUBAREA in the app map, the command verifies: UNDER [COMPONENT] IN APP MAP PART OF COMPONENT
    ---------------------------- ---------------------
    SUBAREA="0,0,10,10" top-left 10x10 square
    SUBAREA="0,80%,100%,100%" bottom fifth


[How To Read This Reference]

GenericMasterFunctions::VerifyObjectDataToFile
Rational Robot Classic Rational RobotJ

Verify the current contents of an object's data with a benchmark file.

Typically, benchmarks are stored in the Datapool\Bench directory. In that event, only the filename.ext is needed. Only an object that Robot can perform an ObjectData VP on can use this command.

The command will produce a TEST WARNING if the user has configured an alternate DIFF tool for which we have no means to compare the diff results. If this WARNING is expected, the user should use the "TW" test record type.



GenericMasterFunctions::VerifyPropertiesToFile
Apple IOS Android

Compare/Verify all of the value properties of a test object with a file.

Compare/Verify all of the value properties of a test object with a file. The benchmark file is expected to be stored in the active "Bench" directory. If you specify a relative path, the path will be relative to the project directory. The directory for a full or relative path must already exist.

GenericMasterFunctions::VerifyProperty
Rational Robot Classic Rational RobotJ Apple IOS Mercury Interactive WinRunner Selenium AutomatedQA Test Complete

Verify the value of a single object property


GenericMasterFunctions::VerifyPropertyContains
Rational Robot Classic Rational RobotJ Apple IOS Mercury Interactive WinRunner Selenium AutomatedQA Test Complete

Verify that the value of an object property contains a string


GenericMasterFunctions::VerifyPropertyToFile
Rational Robot Classic Apple IOS Rational RobotJ Mercury Interactive WinRunner AutomatedQA Test Complete

Verify the value of a single object property with a benchmark file

Verify the value of a single object property with a benchmark file.
Typically, benchmarks are stored in the Datapool\Bench directory. In that event, only the filename.ext is needed. There is currently a limit of 32K allowed for this type of comparison.

The command will produce a TEST WARNING if the user has configured an alternate DIFF tool for which we have no means to compare the diff results. If this WARNING is expected, the user should use the "TW" test record type.



Fields: [ ]=Optional with Default Value
  1. PropertyName
    The case-sensitive name of the object property to verify.


  2. BenchmarkFile
    The name of the file used as the comparison benchmark.

    The name of the file used as the comparison benchmark.
    Typically, benchmarks are stored in the Datapool\Bench directory. In that event, only the filename.ext is needed.


  3. [ FileEncoding = ]
    Specify a character encoding to be used when opening a bench file. If it is not specified, the system default file encoding will be used. The encoding should be a valid string supported by Java; if it is not valid, the system default file encoding will be used instead.


  4. [ FilterMode = ]
    (Future) Specify a file filter to use to process the text before comparison.


  5. [ FilterOptions = ]
    (Future) Specify filter options to use with the file filter.


Examples:
  • T, Browser, HTMLTable, VerifyPropertyToFile, "innerText", aFilename.ext, , "", ""
    Verify the "innerText" property of HTMLTable with the benchmark file.

    Verify the "innerText" property of HTMLTable with the benchmark file.
    The benchmark file is located within the Project at Datapool\Bench\aFilename.ext
    Note the unused reserved fields for FileFilter and FilterOptions.


  • T, Browser, HTMLTable, VerifyPropertyToFile, "innerText", c:\Dir\aFilename.ext
    Verify the "innerText" property of HTMLTable with the benchmark file.

    Verify the "innerText" property of HTMLTable with the benchmark file.
    The benchmark file is not located within the Project. It is at c:\Dir\aFilename.ext


  • T, Browser, HTMLTable, VerifyPropertyToFile, "innerText", c:\Dir\aFilename.ext, "UTF-8"
    Verify the "innerText" property of HTMLTable with the benchmark file.

    Verify the "innerText" property of HTMLTable with the benchmark file.
    The benchmark file is not located within the Project. It is at c:\Dir\aFilename.ext
    The benchmark file will be opened with "UTF-8" file-encoding.


[How To Read This Reference]

GenericMasterFunctions::VerifyTabOrder
Rational Robot Classic Mercury Interactive WinRunner

Attempts to verify the tab order of the specified object--usually a Window.

Attempts to verify the tab order of the current object--usually a Window. A file is used to store the correct tab order of the interface.

The file is simply a list of component names in the order we expect to find them as we tab through the interface. Each line in the file will contain a single component name. That can be either the real valid Name given to the component by development, or the name for the component from the AppMap. The AppMap name is highly recommended to reduce maintenance of the tab order file. Blank lines or commented lines are ignored. Comment lines begin with apostrophe(') or semi-colon(;) characters.

Example file:

  • ;Tab Order Benchmark File
  • ;For ClassicC Login Window
  • (blank)
  • UserIDComboBox
  • PasswordEditBox
  • RememberCheckBox
  • (blank)
  • OKButton
  • CancelButton
This file would normally be placed in the Datapool\Bench directory.

The function will verify that the object order in the interface is the same object order that is in the file. This is done by checking the FOCUS Property of the current object and using the TAB key for navigation. Thus, navigation by the TAB key must be supported by the application.

The routine will only check the tab order for the number of items found in the tab order benchmark file. Thus, the user can perform partial tests on different portions of the interface at different times. Just make sure that the item that currently has the focus is the first item in the tab order benchmark file when invoking this command.



GenericMasterFunctions::VerifyTextFileToFile
Rational Robot Classic Rational RobotJ SAFS TID Commands AutomatedQA Test Complete

Verify the current contents of a text file with a benchmark file (same as VerifyFileToFile).

Verify the current contents of a text file with a benchmark file (same as VerifyFileToFile).
Typically, benchmarks are stored in the Datapool\Bench directory. Typically, files to test are stored in the Datapool\Test directory. In that event, the filename.ext is needed for both files.
The Window and Component objects are not validated and have no role. The Window and Component strings can be any text, but they cannot be blank.

The command may produce a WARNING if a diff tool for which we have no means to verify the results is configured for use. Consequently, if these warnings are expected, the user can use the "TW" test record type to avoid issuing these warnings.



Fields: [ ]=Optional with Default Value
  1. BenchmarkFile
    File used as the comparison benchmark.

    File used as the comparison benchmark.
    This can be a full path, a relative path, or a file name. If it is a filename, it is expected to be in the project's Datapool\Bench directory. If it is a relative path, FindSQAFile is used to located the file.


  2. ActualFile
    File used as the comparison file under test.

    File used as the comparison file under test.
    This can be a full path, a relative path, or a file name. If it is a relative path or a file name, the command will try to find the file in the project's Datapool\Test directory.


  3. [ FilterMode = ]
    (Future) Specify a file filter to use to process the text before comparison.


  4. [ FilterOptions = ]
    (Future) Specify filter options to use with the file filter.


Examples:
  • T, Browser, HTMLTable, VerifyTextFileToFile, bFilename.ext, aFilename.ext, "", ""
    Verify a test text file with the benchmark file (same as VerifyFileToFile).

    Verify the test text file with the benchmark file (same as VerifyFileToFile). The benchmark file is located within the Project at Datapool\Bench\bFilename.ext
    The test file is located within the Project at Datapool\Test\aFilename.ext
    Note the unused reserved fields for FileFilter and FilterOptions.


  • T, Anything, AtAll, VerifyTextFileToFile, c:\Dir\bFilename.ext, c:\Dir\aFilename.ext
    Verify a test text file with the benchmark file (same as VerifyFileToFile).

    Verify the test text file with the benchmark file (same as VerifyFileToFile).
    The benchmark file is not located within the Project. It is at c:\Dir\bFilename.ext The test file is not located within the Project. It is at c:\Dir\aFilename.ext


[How To Read This Reference]

GenericMasterFunctions::VerifyValueContains
Rational Robot Classic Rational RobotJ SAFS TID Commands Mercury Interactive WinRunner AutomatedQA Test Complete

Verify that a string value contains a substring


GenericMasterFunctions::VerifyValues
Rational Robot Classic Rational RobotJ SAFS TID Commands Mercury Interactive WinRunner AutomatedQA Test Complete

Verify that two string values are identical. Note: RobotJ also uses identical keyword 'VerifyValueEquals'


GenericMasterFunctions::VerifyValuesIgnoreCase
Rational Robot Classic Rational RobotJ SAFS TID Commands Mercury Interactive WinRunner AutomatedQA Test Complete

Verify that two string values are identical, ignoring case.