Testim for Salesforce is a test automation platform that enables fast test authoring for Salesforce applications. It brings the fast authoring and AI-powered stability that makes Testim ideal for dynamic applications along with new capabilities to help Salesforce QA teams simplify testing of common use cases.
Salesforce presents challenges that make difficult to perform UI testing:
- Dynamic attributes – The dynamic nature of Salesforce makes the page elements less predictable and therefore renders test automation tests less stable. For example, class names and indexes can change frequently rendering them unreliable as locators. Additionally, Salesforce often changes the underlying CSS in new releases and breaks locators.
- Shadow DOM – Shadow DOM separates the CSS descriptors of an element from the DOM tree. The main challenge is that Salesforce uses Shadow DOM to wrap and protect the internal DOM, so locating and manipulating the components inside the DOM becomes challenging. Many testing tools require special (manual) steps to get below the shadow-tree to the object’s CSS. And even if they are able to “pierce the Shadow DOM,” they often still use a single selector that is flaky.
- Integrations – third-party apps that integrate with Salesforce may require built-in API testing for E2E scenarios. This means that in order to fully test a scenario, your tests must be able to include API actions with other applications.
- Contextual pages – Classic and Lightning web pages and object properties are fluid and may change based on context.
- Apex support – Apex allows developers to execute flow and transaction control statements on Salesforce servers in conjunction with calls to the API. Developers using Apex need to create custom flows, which can become challenging for most test automation tools.
- Role-based logins – Salesforce users often have different role-based experiences that need to be validated. This means that they will need a solution that can streamline the login process within their tests.
Testim was designed to handle Salesforce's dynamic nature. By using AI-powered smart locators, Testim builds a deep understanding of the Salesforce application and automatically handles any changes. Testim recognizes and switches between tabs and frames, automatically creates locators, pierces the Shadow DOM, simplifies custom object handling, and uses group in-context looping to speed authoring and minimize maintenance.
- Fast, flexible authoring – Author, configure and customize stable tests that include API steps to extend scenarios beyond the Salesforce app. No Selenium knowledge is required.
- Dynamic pages – Testim's AI-powered Smart Locators automatically identify and lock in elements of default and custom objects. Testim handles dynamic tables and switches to active tabs automatically. You don’t need to constantly remap locators every time an object is changed.
- Reuse made easy – With Testim you can easily auto-complete a form or reuse a sequence of steps while authoring. Testim allows you to share steps or groups across multiple tests and refactor duplications automatically to create cleaner tests.
- Maintenance – AI-powered locators adjust and auto-improve to keep tests stable and minimize updates, while other tools require hours or days to fix tests when static locators break.
- Shadow DOM handling – Testim automatically handles Salesforce Lightning components behind #shadow-root navigating the shadow tree to access and lock in DOM elements.
- Auto-mapping for styled CSS – For changing attributes like those in Vlocity, Testim auto-maps and filters dynamic classes and IDs to improve the stability of elements.
- Integrated Salesforce login step – The integrated Salesforce Login step allows you to test to login to the Salesforce environment (or sandbox) without the need to record login or logout steps.
- Apex support – Testim supports Apex programming and queries to extend E2E tests beyond the UI, enabling you to fully test your Salesforce scenarios.
Testim for Salesforce is based on the Testim Automate. For additional documentation, please refer to the Testim Automate sections.
Updated 6 months ago