Search here for all the info you want in this Blog

Showing posts with label descriptive. Show all posts
Showing posts with label descriptive. Show all posts

Descriptive Programming (DP) vs Object Repository (OR)

if you ask the difference between object repository and descriptive programming or advantages and disadvantages of both.

everybody will see it in their own view, both has its own advantages and disadvantages

 Object Repository:

    QTP identifies the test object properties which it learns while recording and stores the object properties in the object repository.QTP will use these stored properties while executing the recorded script.

Descriptive programming : this a script method where object properties are directly coded  instead of storing it object repository.
There are two types :
  
   * creating decription object using create.description()
   *You list the set of properties and values that describe the object directly in a     
       VBScript statement

 Advantages of DP over object repository:
 
 a) It is tedious to maintain the object repository, when the size increases.
 b) We have to cautious will using shared repository, if any changes made it will 
     affect  all the tests associated with it.
 c) OR will be time consuming to maintain.





Using Object Repository is a advantage or disadvantage?


As far i think both of them have their advantages and 
disadvantages.

OR is simple and easy to identify the objects. but it 
consumes too much of memory when it is loaded and it will 
increase the execution time. And if you have multiple 
object of similiar kind of object properties at times it 
will fail to recoginzed and the script will fail.

But DP reduces the execution time. Script will not fail in 
this b'coz ur just changing the required property of the 
object, yes it true that initial work more that creating 
object properties list in an excel sheet and load that 
excel sheet during runtime. but this can be overridden buy 
using XML file which is less in size and Quick in loading. 
and it takes very less memory.

let me know if you have any comments on this.

How to handle dynamic objects in QTP?

Dynamic object is an object which changes its properties at the run time and thus its mandatory properties cant be predicted from the starting.

Regular Expression solves the problem of dynamic values in QTP.