Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
which gives better performance qtp with Object repository or qtp without OR.
#1
Solved: 11 Years, 4 Months, 3 Weeks ago
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.
Reply
#2
Solved: 11 Years, 4 Months, 3 Weeks ago
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
Reply
#3
Solved: 11 Years, 4 Months, 3 Weeks ago
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.
Reply
#4
Solved: 11 Years, 4 Months, 3 Weeks ago
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.
Reply
#5
Solved: 11 Years, 4 Months, 3 Weeks ago
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.
Reply
#6
Solved: 11 Years, 4 Months, 3 Weeks ago
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.
Reply
#7
Solved: 11 Years, 4 Months, 3 Weeks ago
I would like to add that there are other methods besides using OR or dp if you are testing a web application.

The article, https://www.learnqtp.com/make-your-qtp-s...rm-better/ demonstrates several methods. Using DOM is faster than either OR or dp.

I went to the Mercury Tours web site, http://newtours.demoaut.com , logged in and went to the “Book A Flight” page. On that page, I ran an OR script and a DOM script that used getElementsByName.

The average of ten runs for the OR script was 2.63 sec.
The average of ten runs for the DOM script was 0.340 sec.

In the above article, the getElementsByName was 26.6 time faster than using OR. While my results are only 7.74 times faster, I tested both edit and list fields. The increase in execution speed is still significant.

hth,

Parke
Reply


Possibly Related Threads…
Thread Author Replies Views Last Post
  How to access webtables without adding into Object Repository ramkumarad 7 9,727 12-30-2013, 07:38 PM
Last Post: Sathiya
  QTP hangs when adding object to the object repository sathya2kn 1 3,507 12-31-2012, 03:33 PM
Last Post: krr
  Object pointer from Repository to Application mollkoff 4 4,517 06-05-2012, 05:26 PM
Last Post: ravs@788
  Is this possbile to write the script without using the Object in object repository? njnirmal 4 8,648 01-03-2012, 05:29 PM
Last Post: shivu.hanu
Exclamation Object Repository Unleash Rajesh 2 3,661 05-11-2011, 11:58 AM
Last Post: Unleash Rajesh

Forum Jump:


Users browsing this thread: 1 Guest(s)