Typical Architecture of Automation FrameworksAn Automation Framework primarily comprises of elements like:
A) Function LibraryB) Object RepositoryC) DatabaseD) Application Scenario FilesE) Initialization VB ScriptF) Sequence FileG) Driver ScriptH) Test Case List File
A) Function Library:
While creating automation framework the entire coding is done by using VB script functions that are user defined. We store these VB script functions in function library files with (*.vbs) extension. Apart from Driver Scripts, there is no need of doing any script creation beyond the function library.
Every application consists of following two types of function libraries
1) Containing common functions that are not dependent on the application functions.2) Containing functions, which are specific, the application.The script designer strives to utilize the common functions, which are independent of the application, to themaximum possible extent. However there is no hard & fast rule to always use common functions only. Whenever there is absolute necessity of using some functions, which are essential for the application, the same are createdon the spot & are stored in the concerned function library.“ExecuteScenarioFile” is a function present in our common function library & is called from the Driver Script or from outside the function library. This function is used for accessing the keywords, various objects and all other parameters from the Scenario File. This is also used to call other relevant functions as well from the functionlibrary.The function library files with (*.vbs) extension are stored in the Function Library folder.
B) Object Repository:
Every application being automated contains a single / unique object repository file. The object repository fileswith (*.tsr) extension are stored in the Object Repository folder.
C) Database:
MS Access database module of MS Office is used to store all the test data. While designing the structure of thedatabase the designer tries to keep one independent table for every screen of the application. Test Case ID fieldis usually designated as the primary key for every table. Test Case ID is unique for every record used by theprogram for iteration. Test Case ID identifier is quite helpful in navigating through some particular type of datastored in the table. QTP establishes a link with database by building its system DSN and using the same DSN in
Leave a Comment