Posts: 19
Threads: 10
Joined: Jul 2010
Reputation:
0
07-20-2010, 01:59 PM
Hi,
I would like to move some reusable actions from tests where i create them to a "repository" test.
I ve found a way to copy them but actually no way to move them and keep them usable in tests where they are used.
Do i need to recreate them in the new "repository" test ?
regards,
Posts: 54
Threads: 2
Joined: Jul 2010
Reputation:
0
07-20-2010, 05:47 PM
Hi,
I don't know how much feasible for you. Try this and see if it is helpful for you.
1. Open QTP, go toTools>Options>Folders tab
2. Set location from where you want look for the scripts using '+' button and make that first in the list to look for
Ex: ...\repository
3. Click OK
4. When you try to reuse the Action, means when you are trying to call Action using "Insert call to Existing Action" use relative path instead of full path.
Ex:
Suppose I have folder structure,
...\Tests\XYZ\scripta
I would provide path in Folder tab till ...\Tests
And when I Call the Action, will provide the relative path to above folder("XYZ\scripta") in From Test to look into.
So, in this way when you change the location of your script, you just need to modify the QTP search file location in Tools>Option>Folders tab.
In your case:
"...\Tests" to "...\repository", so when QTP tries to run a script with a call to a reusable action will not fail due to missing resource.
Alternatively:
Open Missing resources view> Double Click on the link for which it shows Missing Action >In Select Action correct the location
Does it make any sense to your question?
Posts: 19
Threads: 10
Joined: Jul 2010
Reputation:
0
07-21-2010, 02:07 PM
Sasmitakumari,
your solution is interresting as will use it to access reusable actions stored in "repository" test. (actions i will directly create and store in the "repository" test)
but it doesn't answer to the move issue for existing reusable actions already stored in others test.
by the way thanks for your answer.
regards
Posts: 54
Threads: 2
Joined: Jul 2010
Reputation:
0
07-21-2010, 03:39 PM
For existing tests which uses these reusable actions, may be you need to fix them individually using missing resources view after moving/copying the reusable actions to repository.
If you find any other solution, please let us know by posting here.