i am giving you the approach/ solution for data driven. as i said earlier that in data driven, excel sheet / data sheet just contains the data required for passing in application objects.
In your example you need to create 2 columns in datasheet as username and password nd under that pass the required value. thats all your data sheet contains.
for coding / scripting:->
a.create an object to fetch the data from data sheet
b.write the code to set the values in passwd and uname fields.
c. write code for clicking on submit button
d. verify message of success.
all the steps a-d are part of script. datasheet only contains data. thats all.
I keep rest of the things for keyword driven and hybrid for you...I want you to explore yourself to learn it better. Think on it, you will surely crack it!
ALL THE BEST!
hey balaji you yourself answered one question by saying ->Eg : We feed all the data thru datatable and excel and use functions to call those tests.
==> This means you are taking a data from a datatable / excel / doc / txt file/database -> which is nothing but data driven as your test scripts are driven by external data sheets
Keyword driven :-> Keyword driven means you define certain keywords in an excel sheet generally. These defined keywords are actually functions which gets called from a functional library through the help of Macros in excel.
In keyword driven framework commons functionality across application is sorted out and functions for those functionalities get designed; which are nothing but keywords driving the run of scripts called as keyword driven.
eg. signin / sign out / navigation among pages
This is a combination of both frameworks .
so called as hybrid. Normally ppl use hybrid framework/ data driven.
still now a days keyword driven is coming up as its easy for manual testers to run it.
Hey Sorry I really dont have any dump in direct but what all you need to clear the exam is that you should be thorough with all the QTP application. You should know its minute details, how it works, what are the inbuilt functions, what are the setting in QTP ...and all in depth knowledge of it....