Posts: 25
Threads: 11
Joined: Dec 2011
Reputation:
0
01-21-2013, 11:57 AM
(This post was last modified: 01-21-2013, 11:59 AM by qtpexpert.)
Hi,
which gives better performance qtp with Object repository or qtp without Object Repository?
ie
1) qtp by using Object reposiotry with some descriptive programming.
2) qtp with out Object reposiotry(ie object properties we are giving in the test case file) with some descriptive programming.
Kindly let me know the answer any body knows the answer.
i tried with both combinations.
It is taking more time with out Object reposiotry ie(2nd option).
First option is taking very less time.
But I want know the correct answer fro my issue.
Thanks in Advance!...
It would be nice if you share your thoughts. It will be helpful for me.
Posts: 424
Threads: 10
Joined: Aug 2011
Reputation:
0
01-21-2013, 03:24 PM
(This post was last modified: 01-21-2013, 03:25 PM by Ankesh.)
QTPExpert,
OR is an inbuilt feature in QTP which stores information about the objects in your AUT. When you run a script, QTP loads OR at the start in one go and starts using the object information to run the steps. Since the OR loading is happening only once, all objects are accessible throughout the scripts and thus takes less time for execution.
Whereas if you use DP, object informations are available only at runtime. QTP needs to get the description of the object from the code and use it to identify the object in AUT. This increses the execution time. So if you have written the entire script using DP, it increases burden to QTP to read and create a description for object which takes more time for execution.
To use OR or DP is always a debatable topic. It all depends on your choice and scenario. There is no rule for that. I always use OR as it takes less time and the object can be used at multiple places. I opt for DP only in case OR is not feasible for use.
Regards,
Ankesh
Posts: 25
Threads: 11
Joined: Dec 2011
Reputation:
0
01-24-2013, 06:05 PM
Thanks for your reply.
I tried with those two combinations which i have mentioned in my question.
But without object repository and dynamically retrieving the brwoser and page names combination is taking less time.
Posts: 16
Threads: 8
Joined: May 2011
Reputation:
0
01-24-2013, 09:31 PM
Another advantage of using OR is if any property of your object changes, you just need to go and change that at one place. Whereas if we use DP, we need to go into code and change at every line where ever this object is used.
Posts: 22
Threads: 2
Joined: Jun 2011
Reputation:
0
03-19-2013, 12:14 PM
Surya,
What ever you said is correct but its in one scenario only, where the variable u used in every function separately.
If u have declared it as global/ environment variables then u need not change every where, just update the global/ environment variable.
Posts: 91
Threads: 19
Joined: May 2011
Reputation:
0
10-29-2013, 10:18 AM
Hi,
As a good tester we need to find the unique properties of the object and create DP script.
1. If the applciation is stable then go ahead with OR else go with DP (dont forget to use unique properties)
2. If more than one objects has the same properties then go wit h DP where are going to use the regular expression. else use OR
Dependent- OR
Independent - DP
i always prefer DP.