Functional Testing of GUI Applications

It's Worth the Pain

This is an article on the functional testing of desktop (GUI) applications.

It started life as a talk given at PyCon UK 2008.

There is video of me giving this presentation as a 45 minute talk at PyCon 2009: Functional Testing of Desktop Applications

This article goes through both the why and how (the infrastructure and processes involved in testing) of functional testing, and then moves onto some specific examples with a simple application called MultiDoc. MultiDoc is the example application from chapters 3-6 of IronPython in Action).

Introduction Introduction and a look at if it is even possible to test desktop applications.

Why and How Why bother, and the processes and infrastructure around automated functional testing.

User Stories The eXtreme Programming technique for specifying and testing individual application features is done using 'User Stories'.

Testing MultiDoc Part I An introduction to some real functional testing with MultiDoc and unittest.

Testing MultiDoc Part II Having setup the functional tests we need to interact with the application. A look at some techniques to do this, by testing the 'New Tab Page' dialog of MultiDoc.

Problems It isn't always straightforward of course. There are many difficulties and potential frailties in GUI tests. In the conclusion we look at some of the problems and some of the ways you can mimimise the pain.

If you'd like to play with the examples then you can download the full MultiDoc example with test framework and example unit tests and functional tests.