Friday, April 27, 2012

Renamed WinLDTP project as Cobra

Cobra can be used to test GUI applications on Windows platform with the same API set as Linux Desktop Testing Project.

During our testing at VMware it works on Windows XP SP3 / Windows 7 SP1 / Windows 8 development version with Python >= 2.5.

Features supported:

* Most of the widget types are supported and respective actions are supported
* i18n tests can be executed
* CPU / Memory of any application can be monitored

Sunday, April 22, 2012

Select element in system tray (Windows 7) using WDTP

There was a question from my colleague, how do I select an element from system tray icon in Windows 7 using windtp. I came up with the following code:

from ldtp import *
s=getobjectsize('pane0', 'btnNotificationChevron')
generatemouseevent(s[0] + s[2]/2, s[1] + s[3]/2, 'b1c')
s1=getobjectsize('paneNotificationOverflow', 'btnMcAffee*')
generatemouseevent(s1[0] + s1[2]/2, s1[1] + s1[3]/2, 'b3c')
selectmenuitem('mnuContext', 'mnuVirusScanConsole')

He asked me how do get to identify these objects, when I use UI Automation Verify, I could not identify the object as the icon in sys tray disappears after I select something in the tool.

I explained him this what I did to find the object in a python prompt:

First used getojbectlist('pane0') to verify whether its the bottom panel and noticed 'Start' button was part of the output.
Tried clicking all the objects one by one in the tray icon to see which one has all the hidden app icons and found 'Notification Chevron' button.
He asked me why do you use s[0] + s[2] / 2 ... I explained as: to click on the center of the widget, get the object size (x, y, width, height) then do x + width / 2, y + height / 2 and get the center point on the object and do left click (b1c).
Once the app icons popup do right click on the object, which pops up the menu.
Next question from him was, how did you found 'mnuContext' as the window name ?
I did getwindowlist() before right clicking the object and after that as well, with that I found one additional window name in the list which is 'mnuContext'.

Now you are all set for selecting the element from sys tray icon.

Friday, April 20, 2012

VMWare Open Sources Windows Version Of Linux Desktop Testing Project

Today Diksha Gupta of EFY have published an article about Windows GUI automation tool.

Summary from the article:
Linux Desktop Testing Project is a black box (GUI) testing library written in Python. LDTP works based on GNOME accessibility stack, so applications that are accessibility enabled can be automated. Currently GTK, Java Swing, Mozilla XUL, LibreOffice UNO, QT >= 4.8 are supported on Linux. Any GUI application running in Linux, Solaris, FreeBSD with the previous requirement can be automated. With recent addition of WinLDTP, tests in Windows environment can also be automated. This library has been tested with Windows XP SP3, Windows 7 SP1, Windows 8 beta. If the same application exists on both the platforms, with our experience automating VMware Workstation product, we have reused 95 per cent of test automation code across both the platforms, which is a huge win for the QA team. Just develop in one platform and make the minimal required changes to run on other platform and your tests are ready!
Thanks Diksha :-)

Wednesday, April 18, 2012

Announce: Windows version of LDTP - GUI test automation tool

I'm excited to announce Windows version of Linux Desktop Testing Porject (WinLDTP) !!!

Special thanks:
VMware Inc permitting me to open source my work
VMware Desktop Engineering QE team to test it extensively
David Connet for creating the WinLDTP installer

Existing LDTP API's are compatible with WinLDTP, if there is any mismatch then we have to fix it ;-)

About LDTP:

Linux Desktop Testing Project is aimed at producing high quality test automation framework (using GNOME / Python) and cutting-edge tools that can be used to test Linux Desktop and improve it. It uses the Accessibility libraries to poke through the application's user interface. We strive to help in building a quality desktop.

Download source

Download binary (Windows XP / Windows 7)
System requirement: .NET 3.5, refer README.txt after installation

Documentation references:

For detailed information on LDTP framework and latest updates visit

For information on various APIs in LDTP including those added for this release can be got from

Report bugs

To subscribe to LDTP mailing lists

IRC Channel - #ldtp on