Archive for March, 2009

Tracing functions with Instruments

Friday, March 27th, 2009

In Squish we need to intercept the events when recording user interactions and on play back we have to send the events again. So we have to know some details on how the event system in the toolkits work.

To get those details, it is sometimes helpful if you could actually see the functions an application calls. When this need arised on the Mac, I used to use the Activity Monitor which has the ability to sample the application. This is unfortunately not very exact since the samples happen on certain intervals, so you are never sure if the relevant functions are actually sampled.

But Leopard includes the DTrace facility and the graphical frontend Instruments. This allows you to trace a lot of internals of the application, including the functions an application called.

For example you can create in Instruments a new “instrument” that traces all Objective-C calls: simply choose “Build New Instrument…” from the “Instrument” menu and choose the “Probe” of type “Objective-C”. In the dialog I also chose to record the data for “Function” and “Module”. Then just select a target application and press the “Record” button and all the Objective-C calls (including the call stack) are recorded in instruments.

Pretty useful.

But you can also record C function calls: just create a new instrument, this time of type “User Process”. If you record now, you get all the C function calls. This is getting really big really fast (and as a result it the application gets really slow). So what you probably want to do in this case is to limit the functions recorded. I was particularily interested in the functions called in the CoreFoundation framework, so I entered in the line edit after the “hits” text “CoreFoundation” and now the instrument only records functions called in that framework.

Automated Qt GUI testing on Maemo

Tuesday, March 3rd, 2009

Hi!

Since acquiring Trolltech, Nokia is really pushing Qt to all kinds of platforms and devices. This perfectly makes sense considering the gains of having to create the GUIs only once for all different platforms and devices (desktop and embedded) by using the Qt framework.

Historically, and also when looking at our revenue statistics, the Qt market is very important for us. Our automated GUI test tool Squish, which supports testing several GUI technologies such as Qt, Java GUIs, Web, etc. is the leading tool when it comes to automated Qt GUI testing.

We have several customers in the embedded Qt space already. Due to the recent push from Nokia’s side, we decided to offer more dedicated support and resources in this area.

So today we announced that we officially support testing Qt GUIs on the Maemo platform using Squish

In the near future we will add Symbian S60 and Windows Mobile to the list of supported platforms as well.