Releasing HTML DOM Verifier API for the QA Community
Kushan Shalindra Amarasiri
Head of Quality Engineering at Social Catfish
When we automate web UI there is a huge challenge for us to know what elements are modified/added or removed. Most of the automation scripts fail due to this. So the best thing is to know in advance what are these changes and rectify them before execution.
The HTML DOM Verifier API lets us know about this. It allows us to know what elements have changed given the URL of the page.
To download the API use the following link
Next add the dependencies to your POM.xml file
<dependency> <groupId>com.itextpdf</groupId> <artifactId>itextpdf</artifactId> <version>5.5.13</version>
</dependency>
Thereafter add the downloaded JAR file to your test automation project
Import the class used in the API
import org.kushan.html.*;
Call the API method in a test scenario as follows
DOMVerify dv = new DOMVerify();
dv.CheckDOMChanges("https://demo.guru99.com/V4/", "data1.html", "Report1.pdf"); //URL - URL of the web page // The base HTML page // Report name
After each call a report will be generated in PDF with the given name
Please note that further features will be added to this API in future.
QC Analyst at Globant
5 年Perfect, thanks
Full Stack Automation Professional
5 年Outstanding Kushan... It has become a daily practice for me to see your publishes before I read any new paper. Believe me, such is an impact.. :)?