Database testing through Selenium

Data plays a crucial role in any application. Unlike RC & Webdriver there are no libraries provided in Selenium to support database testing. Only Core Java logics will be applied here to perform the databse connectivity and execute sql queries.

In W2A we will see how to create database connectivity and use them in automation framework to perform database testing.



1. Both functional and DB testing can be performed at the same time while running the automation script.
2. Validate data displaying on a webpage and compare the same with database.
3. Send queries (DDL, DML, Joins, Sub-queries etc.)
4. Connect to SQL, MySQL servers etc.

Selenium RC

Database connectivity code

Creating SQL & MySQL Connections :