Web Action Types
Last updated
Last updated
The purpose of this document is to explain the available action types for component web testing.Every step created requires a "Step Description" and "Action Type."
Sometimes, additional inputs are required for an action types and these will be represented as "Required inputs" in this document.
Some action types have the option of "Parameterize," which allows a user to take the input from a .csv file and select which cells will be used while testing (Data Driven Testing).
A step can be made conditional by swiping the "Conditional Step" switch on the step to be made conditional. These steps run only if the conditions of the test meet the criterion. For example, when logging into some apps the first time it might ask to send notifications and usually that is a one-time occurrence. If the pop-up does not appear, the test will continue running without having to "complete" those steps.
We have the following action types :
Alert Handlers:
Alert Text: Purpose: Compare the text of an alert popup with a specified value. Required Inputs: Element's locator type, value, and the text to compare.
Optional Alert: Purpose: Write an alert's content to a file. Required Inputs: None.
Windows:
Attach: Purpose: Switch to a different browser window or tab. Required Inputs: Title of the webpage you want to switch to.
Close Window: Purpose: Close the active window. Required Inputs: None.
Maximize: Purpose: Maximize the window. Required Inputs: None.
Refresh: Purpose: Reload the web page. Required Inputs: None.
Screen Dimension: Purpose: Change the size of the window. Required Inputs: Dimensions.
Set Frame: Purpose: Set the frame to interact with an element. Required Inputs: Element's locator type, value.
Input Event:
Clear: Purpose: Clear the content of an element. Required Inputs: Element's locator type, value.
Send Keys: Purpose: Send specific key strokes to a device. Required Inputs: Key to send.
Set: Purpose: Set the value of an element. Required Inputs: Element's locator type, value, text.
Set by Coordinates: Purpose: Set the value of an element identified by coordinates. Required Inputs: Coordinates, text.
Slider: Purpose: Move a slider to a specific value. Required Inputs: Element's locator type, value, value for slider.
Mouse Event:
Click: Purpose: Click an element. Required Inputs: Element's locator type, value.
Click by Coordinates: Purpose: Click at specific coordinates on the screen. Required Inputs: Coordinates.
Double Click: Purpose: Double-click an element. Required Inputs: Element's locator type, value.
Drag & Drop: Purpose: Perform a drag and drop action. Required Inputs: Initial element's locator, end element's locator.
Highlight: Purpose: Highlight an element. Required Inputs: Element's locator type, value.
Hover: Purpose: Hover over an element. Required Inputs: Element's locator type, value.
Right Click: Purpose: Right-click an element. Required Inputs: Element's locator type, value.
Scroll To: Purpose: Scroll to an element. Required Inputs: Element's locator type, value.
AI:
Click By Image: Purpose: Click on the image of an element uploaded. Required Inputs: Uploaded image of element.
Set By Image: Purpose: Input text into an element specified in the uploaded image. Required Inputs: Uploaded image of element, text.
File and JS Handler:
Click JS: Purpose: Perform a JavaScript click on an element. Required Inputs: Element's locator type, value.
Execute JS: Purpose: Execute JavaScript code. Required Inputs: Element's locator type, value, script.
Execute Java Code: Purpose: Execute Java code at runtime. Required Inputs: Java code, class name, method name.
Verifier:
Contains: Purpose: Check if an element contains specific text. Required Inputs: Element's locator type, value, text.
Element Enabled: Purpose: Check if an element is enabled. Required Inputs: Element's locator type, value.
Element Disabled: Purpose: Check if an element is disabled. Required Inputs: Element's locator type, value.
Element Exist: Purpose: Check if an element exists. Required Inputs: Element's locator type, value.
Element Not Exist: Purpose: Check if an element does not exist. Required Inputs: Element's locator type, value.
Element Position Is: Purpose: Check if an element is in a specific position. Required Inputs: Element's locator type, value, position value.
Element Position Is Not: Purpose: Check if an element is not in a specific position. Required Inputs: Element's locator type, value, position value.
Is Blank: Purpose: Check if a text element is blank. Required Inputs: Element's locator type, value.
Is Visible: Purpose: Check if an element is visible. Required Inputs: Element's locator type, value.
Verify Attribute: Purpose: Verify the attribute of an element. Required Inputs: Element's locator type, value, attribute value.
Verify Attribute Is Not: Purpose: Verify the attribute of an element is not a value. Required Inputs: Element's locator type, value, attribute value.
Verify Greater Than: Purpose: Verify if a value is greater than a given number. Required Inputs: Value to compare.
Verify Less Than: Purpose: Verify if a value is less than a given number. Required Inputs: Value to compare.
Verify Not Null: Purpose: Verify if an element is not null. Required Inputs: Element's locator type, value.
Verify Regular Expression: Purpose: Verify if a text matches a regular expression. Required Inputs: Element's locator type, value, regular expression.
Verify Text: Purpose: Verify the text content of an element. Required Inputs: Element's locator type, value, text.
Verify Text Present: Purpose: Verify if a text is present on the page. Required Inputs: Text to verify.
Verify Text Contains: Purpose: Verify if a text contains specific content. Required Inputs: Element's locator type, value, text.
Verify Title Is: Purpose: Verify the title of the page. Required Inputs: Title to compare.
Verify Title Is Not: Purpose: Verify the title of the page is not a specific value. Required Inputs: Title to compare.
Verify URL: Purpose: Verify the URL of the page. Required Inputs: URL to compare.
Verify Webtable Element Text: Purpose: Verify the text content of a cell in a web table. Required Inputs: Element's locator type, value, row number, column number, text.
Verify Webtable with Excel: Purpose: Verify the content of a web table against an Excel sheet. Required Inputs: Element's locator type, value, Excel file.
Verify Email Body Contains: Purpose: Verify if an email's body contains specific text. Required Inputs: Email subject, expected text.
Verify Email Body Does Not Contain: Purpose: Verify if an email's body does not contain specific text. Required Inputs: Email subject, text to avoid.
Verify Email Subject: Purpose: Verify if an email's subject matches an expected value. Required Inputs: Expected email subject.
Verify Email Attachment: Purpose: Verify if an email contains an attachment. Required Inputs: Email subject.
Verify Email Attachment Type: Purpose: Verify the type of an email attachment. Required Inputs: Email subject, attachment type.
Verify Downloaded File Name/Type: Purpose: Verify the name or type of a downloaded file. Required Inputs: File name or type.
Verify Downloaded PDF Content: Purpose: Verify the content of a downloaded PDF file. Required Inputs: Expected content.
Verify Remote File Contains: Purpose: Verify if a remote file contains specific text. Required Inputs: File URL, expected text.
Verify PDF Content: Purpose: Verify the content of a PDF file. Required Inputs: Element's locator type, value, expected content.
Dynamic Actions:
Dynamic Append: Purpose: Append text to a dynamically generated element. Required Inputs: Element's locator type, value, variable name.
Dynamic Capture Email: Purpose: Capture an email from a dynamically generated element. Required Inputs: Element's locator type, value, variable name.
Dynamic Click: Purpose: Click on a dynamically generated element. Required Inputs: Element's locator type, value, variable name.
Dynamic Contains: Purpose: Check if a dynamically generated element contains specific text. Required Inputs: Element's locator type, value, variable name.
Dynamic Double Click: Purpose: Double-click on a dynamically generated element. Required Inputs: Element's locator type, value, variable name.
Dynamic Exists: Purpose: Check if a dynamically generated element exists. Required Inputs: Element's locator type, value, variable name.
Dynamic Go To URL: Purpose: Navigate to a URL with dynamic values. Required Inputs: URL, variable name.
Dynamic Not Exists: Purpose: Check if a dynamically generated element does not exist. Required Inputs: Element's locator type, value, variable name.
Dynamic Right Click: Purpose: Right-click on a dynamically generated element. Required Inputs: Element's locator type, value, variable name.
Dynamic Set: Purpose: Set values into a dynamically generated element. Required Inputs: Element's locator type, value, variable name.
Dynamic Text Assert: Purpose: Assert if a dynamically generated element's text matches expected text. Required Inputs: Element's locator type, value, variable name, expected text.
Dynamic Verify: Purpose: Verify the value of a dynamically generated element. Required Inputs: Element's locator type, value, variable name.
Dynamic Verify Downloaded File Name/Type: Purpose: Verify the name or type of a downloaded file with dynamic values. Required Inputs: Variable name, file name or type.
Dynamic Verify Downloaded PDF Content: Purpose: Verify the content of a downloaded PDF file with dynamic values. Required Inputs: Variable name, expected content.
Dynamic Verify Is Not: Purpose: Verify the value of a dynamically generated element is not a specific value. Required Inputs: Element's locator type, value, variable name.
Dynamic Verify PDF Content: Purpose: Verify the content of a PDF file with dynamic values. Required Inputs: Element's locator type, value, variable name, expected content.
Dynamic Verify Remote File Contain: Purpose: Verify if a remote file contains specific text with dynamic values. Required Inputs: Element's locator type, value, variable name, expected text.
Conditional:
Start If: Purpose: Begin a conditional block of steps based on a specified condition. Required Inputs: None.
End If: Purpose: End a conditional block of steps. Required Inputs: None.
Data Handler:
Create Variable: Purpose: Capture values from a web element and store for future use. Required Inputs: Element's locator type, value, variable name, property.
Modify Dynamic Value: Purpose: Modify the data of a variable with dynamic values. Required Inputs: Variable name, new text.
Remove Words: Purpose: Remove words from a variable. Required Inputs: None.
Launch:
Go to URL: Purpose: Navigate to a specified URL. Required Inputs: URL.
Launch URL with Auth: Purpose: Launch a URL with authentication. Required Inputs: URL, username, password.
Wait:
Wait: Purpose: Pause execution for a specified duration. Required Inputs: Duration.
Wait for Element: Purpose: Pause execution until a specific element is visible. Required Inputs: Element's locator type, value.
Wait Until Element is Clickable: Purpose: Pause execution until a specific element is clickable. Required Inputs: Element's locator type, value.
Zoom:
Zoom In: Purpose: Zoom in on the current web page. Required Inputs: None.
Zoom Out: Purpose: Zoom out on the current web page. Required Inputs: None.
Zoom Reset: Purpose: Reset the zoom level of the web page. Required Inputs: None.
Refer Web Testing Action Types for more details.