Model-Based Test Automation for Shadow DOM
Generate functional tests for complex web applications
Test Modeller enables rapid and rigorous functional test automation for web applications built with Shadow DOM, moving quickly from application scans to optimised test suites.
More brittle identifiers to maintain?!
Using Shadow DOM offers greater flexibility to web developers but can add to the delays associated with overly manual test automation. Shadow DOM trees often force automation engineers to extract identifiers from multiple roots, laboriously embedding them in test scripts. These test scripts must be highly repetitious in order to test the application logic sufficiently, leading to significant time spent editing, copying and pasting boilerplate code. The brittle test suites then break as the system changes, and Shadow DOM identifiers must be updated. Manual test maintenance in turn prevents rigorous test automation in-sprint, while inaccurate or unavailable test data further leaves web applications exposed to damaging bugs.
Rapid functional test automation for complex web applications
Test Modeller makes testing web applications with Shadow DOM quick, simple and rigorous. An application scanner automatically builds automation modules for each scanned component, incorporating the Shadow Root and CSS identifiers associated with each element. Scanned elements can then be dragged and dropped to intuitive BPMN-style models, leveraging “Fast Modelling” to identify the equivalence classes associated with each element. This rapidly builds logically complete models, before applying automated coverage algorithms to create the smallest set of tests needed to test the modelled web application completely.
The comprehensive test suites are synchronized with ALM and test management tooling, while a customizable code generation engine compiles automated tests for a wide–range of languages and frameworks. Script generation assigns “just in time” data to each test on-the-fly, for continuous test execution without the delays associated with test data. If the web application changes, any impacted elements can simply be re-scanned, rapidly updating complete functional test suites. This automatically re-synchronizes automation frameworks stored in source control systems and test cases in test management tools, maintaining complete functional tests at the speed of rapid releases.
In-sprint test automation for Shadow DOM applications
Watch this short example of model-based test generation for a Java functional test automation framework, and discover how:
Test Modeller’s application scanner automatically identifiers Shadow DOM roots and CSS identifiers, avoiding the time scripting complex and repetitious element locators.
“Fast Modelling” rapidly converts the scanned elements into logically complete models, identifying the equivalence classes associated with each scanned element.
Automated coverage algorithms generate the smallest set of test scripts needed to test the modelled web application rigorously, detecting defects earlier and at less cost to fix
Exporting the optimised test cases to test management tools like Zephyr, Azure DevOps and ALM/Octane creates a link to Test Modeller, auto-updating test cases after test execution.
Updating the central models re-generates and synchronizes the automated test scripts and test cases, enabling comprehensive automated testing in short iterations.