Jump to content

Linux Desktop Testing Project

From Wikipedia, the free encyclopedia
This is an old revision of this page, as edited by Cjbayliss (talk | contribs) at 00:32, 29 March 2014 (Added a ref). The present address (URL) is a permanent link to this revision, which may differ significantly from the current revision.
Linux Desktop Testing Project
Initial releaseError: All values must be integers (help)[1]
Repository
Written inPython, C, C#, Other [2]
Operating systemLinux, OS X, Windows [3]
TypeAutomated testing
LicenseGNU LGPL [4]
Websiteldtp.freedesktop.org/wiki/ github.com/ldtp

The Linux Desktop Testing Project (LDTP) is an open source testing tool that uses uses computer assistive technology[6] to automate GUIs. The GUI functionality of an application can be tested in Windows, Mac, Linux, Solaris, FreeBSD and embedded environments.[7] The Mac OS X version is called PyATOM[8], and the Windows version is Cobra[9].

LDTP can test any accessibility-enabled GNOME application, Mozilla, OpenOffice.org, any Swing-based Java, Qt 4-based and KDE 4.x applications.[10]

LDTP is/was used by the following companies/organizations[11]:

LDTP can be used to remotely test applications.[12]Cite error: A <ref> tag is missing the closing </ref> (see the help page).[13] for Tinderbox integration, Evolution automation, and LDTP regression suite under GNOME organization. Then again in 2007[14][15], it was used by the Mozilla Fondation for Firefox automation and Tinderbox integration.

Example

This is an example of how LDTP would test writing in gedit:

#!/usr/bin/python

# The standard import stuff.
from ldtp import *
import ooldtp 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()

References

  1. ^ "FAQ".
  2. ^ "The Linux Desktop Testing Project OpenSource Project on Ohloh".
  3. ^ "ldtp 3.5.0 : Python Pakage Index".
  4. ^ "Download".
  5. ^ "The Linux Desktop Testing Project OpenSource Project on Ohloh".
  6. ^ "ldtp".
  7. ^ "ldtp".
  8. ^ "pyatom/pyatom - GitHub".
  9. ^ "ldtp/cobra - GitHub".
  10. ^ "ldtp".
  11. ^ "FAQ".
  12. ^ "Executing scripts remotely".
  13. ^ "SoC06".
  14. ^ "SoC".
  15. ^ "SoC07".

See also