Using IBM Rational Functional Tester for the first time

Last May I started my Polteq career with extensive test training, since my work experience so far was not in software testing. In my first assignment I joined a Scrum team that is using IBM Rational Functional Tester (RFT). What caught my attention and could be useful for us to know if we would be in the early stages of RFT use? I would like to share my first experience with RFT to hopefully give you a head start. Please don’t expect me to be a RFT expert, since I have used it for only a couple of months.

Introduction to RFT

RFT is a test recorder, in which we can play back the actions we would like to perform against the application under test. This licensed software can be used for automated functional testing and regression testing. Soon I realized RFT could be used for web based applications and also applications that run on our desktop. The test script we record/ develop is produced as either a Java or Visual Basic.net application. And using the RFT Eclipse Integration, like we did, makes it possible to adjust as desired and enjoy the benefits of working with an IDE (also debugging for instance). Integration of repository management is easy to realize with IBM Rational Team Concert. Because RFT is Java based it gives us the possibility to add external libraries and other tools, for example the Apache log4j logging utility.

RFT is object oriented

The information about GUI objects that RFT interacted with during recording is stored in the so-called Object Map. Test objects we use in our script and which are visible in the Test Objects section of the Script Explorer refer to an object in the associated Object Map. We should know that RFT uses the hierarchical information that is represented in the Object Map and the stored recognition properties to recognize the GUI object during the playback of our recorded script. For readability of our script we would sometimes rename the test objects in the Test Objects section of the Script Explorer, we can do that without any problem because it refers to the Object Map by ID. If an object in the application under test changes, we can update the object in the Object Map, without doing this in the scripts. RFT supports two types of Object Maps: Shared Object Map and Private Object Map. A Private Object Map can only be associated with one script. With this knowledge another question arises. How to organize our project?

Organizing the project

It is useful for us to know that the callScript method can be used to create dynamic regression scripts. This way we can easily include new scripts in our regression test. Organizing our script can be done with the packages (folders in our RFT project). Based on the project we can consider organizing by application, functionality, use cases etc. The scripts in these packages then can contain specific pieces of the application, they can be restricted to specific test objects or whatever suits the project.

How to locate test objects?

I am under the impression that RFT is best used for long term, resilient test scripts, but this requires quite some expertise on how to use the object recognition properties and good knowledge about the (in our case) Java language. Therefore it would be wise to educate ourselves about the recognition properties. For example, we found it useful to learn about the TestObject.find method. This Java™ method enables us to find test objects dynamically, at runtime, based on specific properties. Because it avoids the Object Map you can easily change recognition properties, in comparison to changing stored properties of objects in the Object Map or record the object again to update it. Updating properties in the Object Map can be time-consuming. So the TestObject.find method can come in handy for objects that are likely to change from time to time or for testing multiple versions of an application by using the same script.

Not everything goes without a hitch. RFT is a large program and sometimes it takes a long time to find an object. Besides that, maintaining the Object Maps can become a lot of work. Last but not least I experienced there is less discussion about RFT on forums etc., which also makes it more difficult when we will need some help.

Leave a Reply

Your email address will not be published. Required fields are marked *