Posts: 6
Threads: 2
Joined: Sep 2010
Reputation:
0
09-03-2010, 03:48 PM
Hi All,
is it possible to create a Test Script that records (by interacting with an Add-In) every action?
in other words, instead of using "Record" function of QTP, i'd like to create a Script that makes it automatically (adding other info useful for me)..
is it possible?
Thanks in Advance,
Posts: 22
Threads: 2
Joined: Jun 2010
Reputation:
0
09-03-2010, 06:29 PM
Hi Sborrus,
Your requirement is exactly the same are record function as you it self specified , but why is this requirement ?...Its not an impossible task but its a complex task as far as i know , but is it worth creating it ?... If you analyse your question it all comes down to providing one more Record option isn't ?... Can you please specify what exactly you want to achieve here :-)
Regards,
Balaji
Posts: 6
Threads: 2
Joined: Sep 2010
Reputation:
0
09-03-2010, 07:26 PM
Hi Balaji,
i made a test script that creates a mapping class of all items in a Sap application.
in example:
you can call the method ClickSAPGuiButtonSave, inside the method there's the logic for pointing to Save Button by using Descriptive Programming
Now my idea is to customize recording:
you launch the RecorderTest, first of all it maps the sap window, then it records all your interactions and translate them in calling to mapping class methods..
finally i'll got a test script completely written in Descriptive Programming!
too insane? :-)
Thanks Again for your answer
Posts: 22
Threads: 2
Joined: Jun 2010
Reputation:
0
09-03-2010, 07:45 PM
Hi Sborrus ,
It doesn' t sound insane it sounds great .... Firstly good to know that you are working on a SAP appln
[ I am a former employee of SAP :-) ] ... As per my understanding you want to create a test library of your own ..?Your ClickSAPGuiButtonSave mainly wrappers a logic to call SAP Standard GUI and you want to expose the methods from these GUI objects and perform operations using this API...? So in a way what you do is instead of recording a set of GUI operations , you embedded the recording functions in these set of API's and form a library of your own and customise it according to your requirement ?..... Is my understand rite ?...
Regards,
Balaji
Posts: 6
Threads: 2
Joined: Sep 2010
Reputation:
0
09-03-2010, 08:14 PM
(This post was last modified: 09-03-2010, 08:17 PM by Sborrus.)
yes, you understood.
Actually i have to launch a script for every single Window you meet in SAP application. For every launch my script generates a test library containing a mapping class for a particular window.
It wraps the logic to call an item event (click for Buttons, set for Edit, select for Combo...etc) and exposes only the methods (with a mnemonic) to the outer world for interacting with them in a simpliest way
For now it is a very boring and slow process, but it let me distinguish the logic of a single test script from the visual objects it uses.
So, there's the possibility to create a test script "listener" of the actions in order to let the things faster?
Regards
Posts: 22
Threads: 2
Joined: Jun 2010
Reputation:
0
09-06-2010, 02:48 PM
Yes you can actually do that , your intention might be to create a framework of your own...
Let's think of a rough design perspective. Let's create a library of objects which can access SAP GUI elements and this library can be called within QTP as an Add in( i suppose that is what SAP add in within QTP does) . So your library can have listener objects which are capable of registering the GUI object actions and perform validation steps , so i would say for each family of objects you can create a library .. But there is huge overhead involved when it comes to maintaining this library as it frequent changes to the object definitions could make your library invalid , hence QTP was probably built as a GUI framework with functionalities to update the object repositories dynamically at runtime when the object changes , however to test some standard object you can follow your approach.
Regards.
Balaji
Posts: 6
Threads: 2
Joined: Sep 2010
Reputation:
0
09-13-2010, 07:07 PM
don't you know how can i manage recording in a Test Script?