Record Selenium WebDriver Test Execution Video



Record Selenium WebDriver Test Execution Video

As generic automation the process we usually preferred to capture screenshot of either failed automation test case or screenshot of all test cases as it helps us in debugging and identifying the exact cause of our test cases.

But there are certain situations in our project when we are executing our automation test either using selenium grid or on some remote server or executing as part of the nightly build. In that case if any error or issue occurred during execution it is very difficult and cumbersome to troubleshoot that.

In those situations, or to simply show a demo to the client of our automation script we can video record our execution using Monte Screen Recorder API.



Monte Screen Recorder is java library that helps in creating a video recording of our selenium automation Test.

To use this API we need to download its jar or maven dependency from this link.

Till now only one version for this dependency is present and that I am using it for demo purposes.

Now in the below example, I would be doing a video recording of executing my automation script on google home page and record that in my project structure inside “automationrecordings” folder.

Below is my generic utility class that can be called as per our requirement.



Below is my Test Class.

After execution, we would be able to see video recording generated inside the folder and it can be played using VLC Player.






SHARE THIS

Author:

My Name is Ankur Jain and I am currently working as Automation Test Architect.I am ISTQB Certified Test Manager,Certified UI Path RPA Developer as well as Certified Scrum Master with total 12 years of working experience with lot of big banking clients around the globe.I love to Design Automation Testing Frameworks with Selenium,Appium,Protractor,Cucumber,Rest-Assured, Katalon Studio and currently exploring lot in Dev-OPS as well. I am currently staying in Mumbai, Maharashtra. Please Connect with me through Contact Us page of this website.

Previous Post
Next Post
Anonymous
September 10, 2019 at 3:41 PM

is it possible record the video in mp4 format

Reply
avatar
September 13, 2019 at 2:02 PM

I checked on their Offical page as per last update it supports till .mp3 format

Reply
avatar
November 13, 2019 at 6:41 PM

Awesome i loved it and implemented that in my Project too. Point is about purging of old videos how it can be implemented?

Reply
avatar
April 25, 2021 at 7:22 PM

Its not working for Remote Machine. did anyone knows , how to use for remote machine. For Remote machine its taking blank screen.

Reply
avatar
Anonymous
August 31, 2021 at 1:25 AM

Is there a way to get this working with quicktime on mac?

Reply
avatar