On Feb 5, 2011, at 1:15 PM, dgo...@juno.com wrote:

> Given your feedback below, is appscript+System Events a reasonable approach 
> for test automation?

I'm sure there are many with greater experience, but I'd second everything has 
said about scripting system events: brittle and fiddly pretty well sums it up.

UIBrowser would be essential to keep your sanity, and you should program in 
py-appscript instead of Applescript.

One of the things that I find most bothersome is the timing of actions: some 
commands can't be made before a menu or window is instantiated. I've found 
often that KeyboardMaestro often gets around these issues, but on the other 
hand, doesn't offer as complete access to System Events as py-appscript would. 
KeyboardMaestro is itself py-appscript-able, so you could mix and match at will.

Also, a lot is dependent on your application(s) supporting System Events, which 
isn't (still) always the case.

So, I think you could use py-appscript to aid your testing, which isn't 
impossible to do, but as things get more complex and big, your scripts might 
become un-manageable. If you can split your testing into smaller tasks, you'll 
be in better good shape.

HTH, Charles



_______________________________________________
Pythonmac-SIG maillist  -  Pythonmac-SIG@python.org
http://mail.python.org/mailman/listinfo/pythonmac-sig
unsubscribe: http://mail.python.org/mailman/options/Pythonmac-SIG

Reply via email to