Re: how do I automate testing of Tk programs?





Matt wrote:
I've read a little about expect, but it doesn't seem to interact using mouse clicks. Maybe I am wrong about that ...

no, you are correct - expect handles interacting with apps via terminal
IO - not GUI

One simple thing I would like to do would be to automatically record a sequence of mouse clicks and keypresses so that I could replay the sequence to the Tk program under test.

Is that possible, and where do I start?

It is possible, there are commercial GUI testers (XRunner for unix boxes
comes to mind), but a good starting point is Android

http://wiki.tcl.tk/Android has info on this, as well as links
to a couple of other tools.

Another thing to think about if this is an app you are developing
you can ass hooks to all the functionality taht the GUI provides
in order to provide scripted control and testing.

Bruce
.



Relevant Pages

  • Re: Handling outputs (yes, an *on* topic thread!)
    ... Perhaps, in the future, ordering a part would create as response for ... >> column that gives the sequence of messages, and rows within a message, by ... Anything else will be deleted when the user logs out ... Like I said, for the GUI, we're already using a table. ...
    (comp.lang.cobol)
  • Re: GUI Wizard: flow control?
    ... > I'm trying to use python to create GUI wizards, ... I am assuming that your chosen GUI allows you to easily choose ... You create a list a panels, each of which you have constructed using ... a function that displays the preceding panel in the sequence. ...
    (comp.lang.python)
  • Re: Multithreading and GUI updaing
    ... Queue and the BackgroundWorker make sure the events are in sequence. ... mentioned use a third thread to Invoke the GUI thread, ... second), I end up with load of these background threads, which then invoke ... Invoke - halts the worker thread while waiting for the GUI thread to ...
    (microsoft.public.dotnet.framework.compactframework)
  • Re: Happy Hacking Keyboard
    ... > Well, Kevin, you'll just have to assign any sequence not already in use. ... > In Joe, I use CTRL+sequences for lots of things. ... with the power of GUI. ...
    (alt.os.linux.suse)
  • Re: Logging starategy
    ... Logging WM_ messages will almost certainly result in failure. ... One approach is to divide your program into two components: GUI manipulation and object ... The GUI is just a way to manipulate objects. ... Note that this only works if your initial state on replay is identical to the initial ...
    (microsoft.public.vc.mfc)