The Linux Desktop Testing Project (LDTP) is an
open-source
Open source is source code that is made freely available for possible modification and redistribution. Products include permission to use the source code, design documents, or content of the product. The open-source model is a decentralized sof ...
testing tool that uses computer
assistive technology to automate
GUI
The GUI ( "UI" by itself is still usually pronounced . or ), graphical user interface, is a form of user interface that allows users to interact with electronic devices through graphical icons and audio indicator such as primary notation, inste ...
s. The GUI functionality of an application can be tested in Windows, Mac, Linux, Solaris, FreeBSD and embedded environments. The Mac OS X version is called PyATOM, and the Windows version is Cobra.
LDTP can test any accessibility-enabled
GNOME application,
Mozilla
Mozilla (stylized as moz://a) is a free software community founded in 1998 by members of Netscape. The Mozilla community uses, develops, spreads and supports Mozilla products, thereby promoting exclusively free software and open standards, w ...
,
OpenOffice.org, any Swing-based
Java
Java (; id, Jawa, ; jv, ꦗꦮ; su, ) is one of the Greater Sunda Islands in Indonesia. It is bordered by the Indian Ocean to the south and the Java Sea to the north. With a population of 151.6 million people, Java is the world's mo ...
,
Qt 4-based and
KDE
KDE is an international free software community that develops free and open-source software. As a central development hub, it provides tools and resources that allow collaborative work on this kind of software. Well-known products include the ...
4.x applications.
LDTP is/was used by the following companies/organizations:
*
GNOME
*
Mozilla
Mozilla (stylized as moz://a) is a free software community founded in 1998 by members of Netscape. The Mozilla community uses, develops, spreads and supports Mozilla products, thereby promoting exclusively free software and open standards, w ...
*
Openoffice.org
*
KDE
KDE is an international free software community that develops free and open-source software. As a central development hub, it provides tools and resources that allow collaborative work on this kind of software. Well-known products include the ...
*
Novell
Novell, Inc. was an American software and services company headquartered in Provo, Utah, that existed from 1980 until 2014. Its most significant product was the multi- platform network operating system known as Novell NetWare.
Under the l ...
/
SuSE
SUSE ( , ) is a German-based multinational open-source software company that develops and sells Linux products to business customers. Founded in 1992, it was the first company to market Linux for enterprise. It is the developer of SUSE Linux En ...
*
Palm Source
*
VMware
VMware, Inc. is an American cloud computing and virtualization technology company with headquarters in Palo Alto, California. VMware was the first commercially successful company to virtualize the x86 architecture.
VMware's desktop software ru ...
LDTP can be used to remotely test applications.
The LDTP is released under the
LGPL.
History
LDTP version 0.1.0 was released in January 2005 and then showcased and discussed at
GUADEC
GUADEC, the GNOME Users And Developers European Conference, is an annual developer conference, whose prime topic is the development of the GNOME, GNOME desktop environment and its underlying base software, such as GTK, GStreamer, etc.
The first ...
2005. It was then used at the
Google Summer of Code
The Google Summer of Code, often abbreviated to GSoC, is an international annual program in which Google awards stipends to contributors who successfully complete a free and open-source software coding project during the summer. , the program is ...
in 2006 for
Tinderbox
A tinderbox, or patch box, is a container made of wood or metal containing flint, firesteel, and tinder (typically charcloth, but possibly a small quantity of dry, finely divided fibrous matter such as hemp), used together to help kindle a fi ...
integration,
Evolution
Evolution is change in the heritable characteristics of biological populations over successive generations. These characteristics are the expressions of genes, which are passed on from parent to offspring during reproduction. Variation ...
automation, and LDTP regression suite under
GNOME organization. Then again in 2007,
it was used by the Mozilla Foundation for
Firefox
Mozilla Firefox, or simply Firefox, is a free and open-source web browser developed by the Mozilla Foundation and its subsidiary, the Mozilla Corporation. It uses the Gecko rendering engine to display web pages, which implements current and ...
automation and
Tinderbox
A tinderbox, or patch box, is a container made of wood or metal containing flint, firesteel, and tinder (typically charcloth, but possibly a small quantity of dry, finely divided fibrous matter such as hemp), used together to help kindle a fi ...
integration.
Example
This is an example of how LDTP would test writing in
gedit
gedit ( or ) is a text editor designed for the GNOME desktop environment. It was GNOME's default text editor and part of the GNOME Core Applications until GNOME version 42 in March 2022, which changed the default text editor to GNOME Tex ...
:
#!/usr/bin/env python3
# The standard import stuff.
from ldtp import *
from ooldtp import context as locate
from time import sleep
# Here we open the app.
launchapp("gedit")
# Now we find it and make sure it is open.
gedit_win = locate("*gedit")
gedit_win.waittillguiexist()
# Now we type into gedit.
text_field = gedit_win.getchild("txt1")
text_field.enterstring("G'Day mate!")
# Save a picture to prove we did it.
imagecapture("*gedit", "/tmp/foo.png")
# Quit gedit.
quit = gedit_win.getchild("mnuQuit")
quit.selectmenuitem()
# Close without saving.
dont_save = locate("Question")
dont_save.waittillguiexist()
button = dont_save.getchild("btnClosewithoutSaving")
button.click()
# Wait until gedit is gone.
gedit_win.waittillguinotexist()
Diagram of how LDTP works
See also
*
List of Linux GUI testing tools
GUI testing tools serve the purpose of automating the testing process of software with graphical user interfaces.
References
{{reflist
GUI
Software comparisons ...
*
Desktop Linux
Besides the Linux distributions designed for general-purpose use on desktops and servers, distributions may be specialized for different purposes including computer architecture support, embedded systems, stability, security, localization to a spec ...
References
External links
*
MagoUbuntu wrapper using LDTP
{{FOSS
Freedesktop.org
Free software programmed in Python