Debug automated GUI tests on a headless Jenkins CI server running Ubuntu

When you are running automated GUI tests on a box without any windowing system, it is hard to debug problems.

So our main question is: how can we have a look at the tested UI while the tests are running?

Preconditions:
- headless GUI tests on Ubuntu
- Jenkins Xvnc Plugin (in Jenkins / Hudson, Manage Jenkins -> Plugins -> Install new plugins, choose the xvnc plugin)

You have to first find out what the port is that Xvnc is listening to on your Ubuntu machine:

$ ps -ef | grep vnc

user 29200 1568 0 10:56 pts/0 00:00:00 Xtightvnc :55 -desktop X -auth /home/user/.Xauthority -geometry 1024x768 -depth 24 -rfbwait 120000 -rfbauth /home/user/.vnc/passwd -rfbport 5955 -fp /usr/share/fonts/X11/misc/,/usr/share/fonts/X11/Type1/,/usr/share/fonts/X11/75dpi/,/usr/share/fonts/X11/100dpi/ -co /etc/X11/rgb -localhost -nolisten tcp

OK, looks like Xvnc is listening on-rfbport 5955 in this case.

You can then use a vnc viewer of your choice (on ubuntu, vinagre is a good choice) to connect to your ubuntu box on port 5955.

Install vinagre: $ sudo apt-get install vinagre

Start vinagre and connect your vnc viewer to localhost:5955 and observe the magic!

unitec-info

You are a serious company. You deserve a serious solution.

Contact Info

unitec informatics gmbh
You want to write us?
+49 69-967-516-00
Mergenthalerallee 10-12, 65760 Eschborn
shiraznet1