Using python binding selenium3 webdriver for test automation, to record execution steps using castro but it is failing on Windows 7 x64.
Is there any other library or mo
The reason is you have not enabled vnc loop back connection.
I do not recommend using castro. It's really outdated, I've tried using it in my own tests and did get it running but it was too unstable.
I'm currently using ffmpeg together with screen-capture-recorder (screen recording software) and it works like a charm. It allows you to set the framerate, resolution, bitrate as well as chose different video codec.
The code looks like this :
from subprocess import Popen
from subprocess import call
cmd = 'ffmpeg -y -rtbufsize 2000M -f dshow -i video="screen-capture-recorder" -s 1920x1080 -b:v 512k -r 20 -vcodec libx264 test.avi'
def terminate(process):
if process.poll() is None:
call('taskkill /F /T /PID ' + str(process.pid))
videoRecording = Popen(cmd) # start recording
terminate(videoRecording) # terminates recording
Selenium provides us with the feature to run the automation code/suite and record the output as a video and save it on your system. This video can then be shared with anyone who can see what the automation is doing. First of all, to enable video recording, we need to download some important jars. They are freely available to download from Google. Below are the jars to be downloaded. These are the latest version available, any other version can also be downloaded:
ATUReporter_Selenium_testNG_5.1.1 ATUTestRecorder_2.1
You can find the complete code in below link: https://mytechdevice.com/how-to-record-video-of-automation-output-in-selenium/