Tag-Archive for ◊ QTP ◊

Author:
Wednesday, August 18th, 2010


There seems to be a bit of controversy regarding QTP’s Smart Identification feature. A cursory Google search tells me that some people consider it utterly useless, while others see it as a useful, indispensable part of their arsenal when creating tests. So I suppose the question is, is it useful, or a waste of time?

First, Smart Identification (SI) is an algorithm within QuickTest that kicks in when, within the code and repository, two elements look the same to QTP. SI then takes a peek at the the object in question, in an attempt to sniff out a property to distinguish an element from its look-alike cousin. If it finds such a property, it will let QTP know what it should be doing with that element. In a nutshell, it’s doing what the tester should have done in the first place: Looking for a good, unique property of an element, so that QTP is able to take a look at the script and immediately know which object on the page it’s supposed to be carrying out the task at hand on.


So getting back to the question at hand, the answer is ‘Yes’, because it can be useful, particularly to someone not particularly familiar with the ins and outs of QTP, ie. a novice, who may not know to how or when to employ the use of descriptive properties. It can also help out as a helpful reminder in case of an oversight. 

And the answer is ‘No’, because the experienced tester should have a feel for when and where to properly describe all the elements used in their test. It’s also a bad idea in case a tester does not know how to read the results correctly, and assumes because their script is ‘working’, they did everything correctly. 

In the end, the usefulness of Smart Identification probably depends on the experience level of the tester more than anything, rather than being a black and white issue.

J9 Test Asset Developer
Category: J9 Blog and News  | Tags: , , ,  | Comments off
Author:
Tuesday, August 10th, 2010

While working on my current project I have been writing programs that test the functionality of our clients upgrades they are making on their main client database. Now, keep in mind that when companies re-write their applications and databases…they have two environments. They have their LIVE and they have their TEST. I use the TEST environment very frequently but, when I write a program that does not save information I test it in both. This week I ran into an issue, one that completely blew me away. It seems that its always the little things that aggravate you the most.

Once I was done writing my code I tested my program in our clients test environment which is accessed through Internet Explorer. Worked like a charm, on the first try even! In the programming world, that does not happen very often. Anxiously, I switched over to their live environment which is also accessed in Internet Explorer. I was not so lucky this time around. This code just worked, flawlessly, but now something is broken. By broken I mean every text field, check box, and button I was verifying would not be recognized by QTP.

I quickly go back to the test environment and run it again. Unbelievably, it fails in this environment as well. Right away I knew that it had something to do with switching the applications. The issue that perplexes me the most is that when I switch between test and live environments, all I change is ONE letter in my URL.

With this in mind, when using QuickTest Professional and you are switching between environments that use the same interface (like Internet Explorer), always make sure to close IE completely and do not simply just change the URLs. It will save you time, energy, and your sanity.



J9 Test Asset Developer

Category: J9 Blog and News  | Tags: , ,  | Comments off
Author:
Friday, August 06th, 2010
On my current project, I have been updating business components that were recorded against an Oracle platform with a JAVA presentation layer.  Initially, due to some object recognition issues with the Oracle add-in we were forced to use just the JAVA add-in by itself.


Since these component recordings the client has implemented a patch to their Oracle instance, that has “corrected” a lot of the object recognition issues that we were having. Now we are able to use the Oracle add-in thus enhancing QuickTest’s functionality against the Oracle forms.


We originally encountered many aggravating  issues with using the JAVA add-in only, for example all edit field entries were being recorded with the same object name, and all were using the SetSecure method opposed to the Set method used to enter data.


Once the Oracle patch was implemented, one problem I encountered was that I was unable to record an action that required clicking on a sub-tab called “Collections.”   This tab was to be activated in order to interact with the fields it contained. Normally QuickTest has no issues at all with selecting items within a tab strip (in other environments), but on the Oracle environment it simply would not register. I “spied” on the object and found no identifying characteristics except for the name.  With such a powerful identifying trait why would QTP not recognize this action when recording?  My first inclination was to do Low Level Recording.  However, this is only used as a last resort so I decided to try adding the tab to the repository and added …OracleTabbedRegion(“Collections”).Select to my code.


Ultimately, this was the correct fix.  It is important to remember or search through the vast amounts of objects and methods when working with advanced scripting.  A little extra effort can truly enhance the quality of your work.


J9 Test Asset Developer



Category: J9 Blog and News, Uncategorized  | Tags: , , ,  | Comments off