This is a repository of custom action steps that work with Testim.io
These are not officially supported by Testim, but rather examples to try and modify to fit your specific test cases.
If you have an idea for a custom action example feel free to submit a GitHub issue.
Initially it includes custom action steps (JavaScript) that we have created for customers. The code can be copied from here and added to a custom step in a Testim test. Instructions on how to use each example are included in the linked file with the JavaScript code needed. Typically it will involve copying the file and code into a custom step, making a change or two to the properties panel, checking your variables, and perhaps pointing to the correct element.
Testim Test Result Report Generator - Generate Detailed HTML/PDF Test Report(s) with optional screenshots, test data and network summary performance data
AfterStep - Extended (Hook Function) - Collect enhanced step information for AfterTest reporting
After Test Hook - JSONDBFS (Hook Function) - Collect test results gathered during a test run and insert into a JSONDBFS Database Collection (file)
After Test Hook - SQL Server (Hook Function) - Collect test results gathered during a test run and insert into a SQL Server database table
Network Performance Summary - Creates a summary of network requests with min/max/avg duration and request size that can be included in the test report.
Classes Get - Get an element's class list as a string array
Element(ByText) - Click - Find an element by Text and click it
Element(ByXPath) - Click - Find an element by XPath and click it
Element(ByCSS) - Click - Find an element by CSS and click it
Element Neighbor Click/Select - Find an element by AI/Text/XPath or CSS and optionally a neighboring element based on xpath or relative position
Excel - Import Data - Process Excel download file and save sheet data values as test data (testData)
Generate Faked Data (faker.js) - Uses the faker.js library to create fake test data.
Redact data - This custom step creates an overlay element to prevent screenshot capture of private data.
Set Text (Redacted) - Redacts a field and then sets its text
Image Element Capture-Validate - Capture an image of a DOM element and optionally validate (pixel exact match)
Link Checker (CLI) - Finds links at the given URL and validates that they are working.
Network Validate Request - Validate that a network request returns the proper status and/or is not slower than maxDuration (ms).
Numeric Expression Validate - Validate a value using numeric expressions ">", ">=", "==", "<", "<=".
Email - Validate - Process email inbox and validate/parse last message for subject/body and optional regex to pull specific data and links
isEnabled - Vaildate that an element is enabled (or disabled)
isVisible - Vaildate that an element is visible
isPlaying - Validate that a video/media element is currently playing video (or not)
hasClass - Check if an element's class list includes certain expected classes
Element Computed Style(s) - Validate - Validate a superset/subset of style for an element
MongoDB Query - Execute a MongoDB Query and return results
MySQL Server Query - Execute a MySQL Query and return results
SQL Server Query - Execute a SQL Server Query and return results
SQL Server - Results Validate - Execute a SQL Server query, validate and return results
JSONDBFS Query - Read/write data from/to local json files on disk using NoSQL query syntax.
AzureDevOps wiQL Query - Execute a wiQL (Work Item Query Language) query in Azure DevOps and return results
AzureDevOps WorkItem Create/Update - Create or Update a Work Item in Azure DevOps
SOAP Request - Execute a SOAP request and return results
graphQL Query - Execute a graphQL Query and return results
PDF - Download-Process-Validate - Download, parse and validate a PDF document
PDF - Fields/Texts Validate - Validates text blocks and fields using pdfDocumentTexts and pdfDocumentFields from "Download-Process-Validate PDF" step
Select Items/Options - Select an item by value or text (select/option, ul/li)
Select Items/Options - Validate - Validate that expected items are in a list/select.
Select Items/Options Order - Validate - Validates that the items in a list are sorted properly.
Debug Popup - Displays in a modal popup window for debugging purposes
Watchlist Popup - Display Testim and User defined variables in a popup window (div)
Popup Killer - When you don't know when a popup modal will kill your test, use this to handle it.
Alert Override - Overrides the window.alert function to dispaly an alert as a popup div to enable validation of javascript alert
AfterStep (Hook Function) - Collect step information for AfterTest reporting
AfterStep - Extended (Hook Function) - Collect enhanced step information for AfterTest reporting
AfterTest - Azure Devops (Hook Function) - Create a new or update an existing work item (bug) with test results
After Test Hook - SQL Server (Hook Function) - Collect test results gathered during a test run and insert into a SQL Server database table
After Test Hook - JSONDBFS (Hook Function) - Collect test results gathered during a test run and insert into a JSONDBFS Database Collection (file)
Transaction Begin - Start a transaction.
Transaction End - End a transaction.
Transaction Summary Report - Log/Report all transactions.
Network Performance Checker - Validate that all network requests are completed under maxResponseTime milliseconds.
Network Performance Summary - Creates a summary of network requests with min/max/avg duration and request size.
Table - Validate - Validate table cell content
Table - Cells Get - Get all table cell values
Table - Cell Get - Get the content a specific cell within a specific row in a table
Table - Cell Click - Click on a specific cell within a specific row in a table
Table - Column Order Validate - Validate the values in a column are sorted properly
Shell Command Execute - Runs a shell command and returns stdout