Posts: 2
Threads: 1
Joined: Dec 2009
Reputation:
0
12-17-2009, 06:46 PM
I have a number of common operations that I regulary perform in my test scripts like StartApp, StopApp, Login etc.
I would like to collect these together into a QTP function Library.
How do i associate the Object Repository to the Fuction Library and to reference the objects in the repository in my scripts ?
TIA
Posts: 25
Threads: 2
Joined: Jul 2009
Reputation:
0
12-17-2009, 09:43 PM
If I'm not mistaken, the Object Repository is associated with the test not with the function library. You would associate the Function Library to the Test and then you can use those functions in the test and also the Object Repository.
Posts: 2
Threads: 1
Joined: Dec 2009
Reputation:
0
12-18-2009, 12:23 AM
Yes but in my case I want to have QTP recorded operation in the function Login.
So I guess the function library needs to then know about the Object Repository.
The Test Case would just call a function called Login in the function library and the Login screen operation would occur.
I suppose the question is if it is really valid to have function library's that contain recorded actions?
Posts: 1,105
Threads: 18
Joined: Jan 2008
Reputation:
8
12-18-2009, 12:29 AM
I would prefer to keep things simple in such cases and would use Descriptive Programming to write statements in function library.
No OR, therefore no association required.
Posts: 6
Threads: 1
Joined: Feb 2011
Reputation:
0
02-03-2011, 03:14 PM
Hi,
Use Function Library with Shared Object Repository(SOR)
or
Use Function Library with Descriptive Programming
in the 1st case Associate SOR to the actions whenever you use the library function