Selenium Tutorials

Selenium 3 - Launch Edge browser using Microsoft Edge Driver

In the previous article, we have seen launching Firefox browser with Gecko driver using Selenium 3. Now let us try to launch Microsoft Edge browse using Selenium 3.

Before proceeding, to start using Webdriver with Microsoft Edge browser, make sure you have Windows 10 on your machine and download the specified Microsoft WebDriver server version for your build.

Selenium 3 - Launching firefox browser using Geckodriver

The first example that we will look into is launching firefox using the Geckodriver. When using Selenium 3 , you have to download geckodriver. Just like the other drivers available to Selenium, Mozilla has released geckodriver executable that will run alongside the browser.

You can download the latest executable on the GitHub page. Now you need to specify the system property with the path

Execute webdriver tests in Parallel using selenium Grid

In previous article we have seen configuring selenium grid and execute a simple test on firefox browser. In this tutorial we will see 'Parallel execution of tests' using selenium grid and execute tests on firefox and chrome browser.

We will register multiple nodes to the Hub and execute tests in parallel. In the below example we will register a node in the same local machine where hub is running and other node in remote machine.

How to Setup a Hub and Node for Selenium Grid

Selenium Grid allows us to execute our tests in multiple machines (physical / virtual) and multiple browsers with different versions, which dramatically speeds up test execution and helps in reducing total amount of time required for test execution.

For example, if we have a script that takes 100 minutes to execute sequentially , we could break that down to 10 short tests script run across 10 machines, and can complete them in 10 minutes without copying your test code to the other machine.

Webdriver Event Listener example

Webdriver events are helpful to view the events triggered by webdriver. It also plays an important role in analyzing results and helps us in debugging issues if we encounter any.

Selenium webdriver has ability to track different events such as 'beforeNavigateTo' , 'afterNavigateTo' , 'beforeClickOn' , 'afterClickOn', 'onException' and so on. When ever we develop test scripts we can write our own implementation for handling events during the execution.

How to do Database testing using Selenium Webdriver Framework Example

In previous tutorial, we have discussed about database testing and JDBC Java API which is primarily used to connect and interact with Database. Check out the simple example of Database testing with selenium.

In this tutorial, we will discuss how to perform database testing in different environments and pass the parameters to different methods in a simple way.

Database testing using Java, Selenium, TestNG example

As we know every application has to maintain a database like My SQL, Oracle or any other databases to store all its data. And where as Selenium Webdriver is used for testing web applications and we perform many operations like submitting information and some times retrieving information and validate them.

In selenium scripts, when there is a need of getting the Data from the database we may have to use APIs which helps to interact with database like JDBC.

Handling Untrusted SSL certificates in Firefox browser

Before jumping on to the example, first let us see What is SSL Certificate and When do we get UNTRUSTED CONNECTION Alert / Error.

Firstly, WHAT IS SSL CERTIFICATE ?

SSL is used to keep sensitive information which is sent across the Internet encrypted so that only the intended recipient understand it. This is important because, the information that we send on the internet is passed from one system to other system to the destination server.