Object repository types in QTP

By | December 21, 2010

Object repository types in QTP
I have been asked many times about doubts regarding object repository types and their extensions in QTP, most learners are confused between local object repository, shared object repository and per action repository. Here I have tried to explain object repository types in QTP.
I am sharing following information depending on my own QTP experience, I may be wrong but I will try my best to share the true knowledge what I have.
There are basically two types of object repository.
  • ·         Local object repository
  • ·        Shared object repository
Local object repository:
Local object repository is the object repository which is specific to QTP test (for e.g. test1) and not available for another QTP test (e.g. test2).
The extension of Local object repository is .bdb (berkley data base), lots of people considered .mtr as local object repository. But let’s verify and clear the confusion between local object repository extension (.bdb or .mtr) by following simple  steps.

1.       Create one QTP test.
2.       Record some web page and store the QTP test file.
3.       Copy and  rename Action1->ObjectRepository.bdb file to MyRepository.tsr
4.       Open QTP and open MyRepository.tsr file through Resources->Object Repository Manager.
5.       Now you can see the objects recorded by you.

Note: Using above steps we can conclude that .bdb is the local object repository. In above steps we made local object repository to shared object repository by changing its extension from .bdb to .tsr so that we can view the objects from .bdb file.
Shared object repository
Shared object repository is the global object repository which we can use for any QTP test by associating it. We have already covered associating shared object repository to any QTP test. The extension of shared object repository is .tsr. (test shared repository).
.mtr (module test repository) is the extension of per action repository which contains checkpoints and other stuffs. It is a binary file. If you have more practical knowledge regarding .mtr you are always welcome to share.
All QTP experts are welcome to share their thoughts on object repository types in QTP.
If you like this article, You can subscribe through mail.

One thought on “Object repository types in QTP

Leave a Reply

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