I just glanced at DogTail: + GUI testing written in Python + Allows some querying/setting of actual fields. - Not maintained for past couple years - Most documentation and examples missing - Test cases appear verbose, but hard to tell with all examples missing. - Testing uses 'tree' approach requiring manaully setting focus and such. - Relies on all sorts of stuff, including the disability libraries and CORBA of all things to send messages.
Here's a good document: http://www.redhat.com/magazine/020jun06/features/dogtail/ Here's a sample test script: # Focus gedit's text buffer. 25 focus.text() 26 27 # Load the UTF-8 demo file. Use codecs.open() instead of open(). 28 from codecs import open 29 from sys import path 30 utfdemo = open(path[0] + '/data/UTF-8-demo.txt') 31 32 # Load the UTF-8 demo file into the text buffer. 33 focus.widget.text = utfdemo.read() 34 35 # Click gedit's Save button. 36 click('Save') 37 38 # Focus gedit's Save As... dialog 39 focus.dialog('Save as...') 40 41 # click the Browse for other folders widget 42 activate('Browse for other folders') 43 44 # Click the Desktop widget 45 activate('Desktop', roleName = 'table cell') Overall, DogTail spends most of its effort getting around the PyGTK limitations about exposing the entire tree. It uses the accessibility UI as a substitute for having an API into PyGTK. Most of the test script is mucking around getting focus, etc. Anyone actually use DogTail still? Charles On Thu, Mar 27, 2008 at 5:55 AM, Chris Ball <[EMAIL PROTECTED]> wrote: > Hi Charles, > > > > Consider adding it the the GObject functions. Call a new > > gobject.dump_main_context() and get a huge Python data structure > > back. > > You're describing at-spi¹, which is an accessibility framework that > provides introspection on GUI widgets. There's an existing GUI test > framework called Dogtail², written in Python, that uses the widget data > from at-spi in order to allow easy addressing of widgets for writing > GUI tests for GTK apps. > > It would be a great project for someone to look into what it takes > to get Dogtail working on the XO. It has some gnarly dependencies > (bonobo, corba..) but there wouldn't be a need to put them in every > build, just builds that we want to run a test harness against. > > Thanks, > > - Chris. > > ¹: http://developer.gnome.org/projects/gap/ > ²: http://people.redhat.com/zcerza/dogtail/ > -- > Chris Ball <[EMAIL PROTECTED]> > _______________________________________________ Testing mailing list [email protected] http://lists.laptop.org/listinfo/testing
