Micro Focus QTP (UFT) Forums
Driver Script to control child scripts - Printable Version

+- Micro Focus QTP (UFT) Forums (https://www.learnqtp.com/forums)
+-- Forum: Micro Focus UFT (earlier known as QTP) (https://www.learnqtp.com/forums/Forum-Micro-Focus-UFT-earlier-known-as-QTP)
+--- Forum: UFT / QTP Beginners (https://www.learnqtp.com/forums/Forum-UFT-QTP-Beginners)
+--- Thread: Driver Script to control child scripts (/Thread-Driver-Script-to-control-child-scripts)



Driver Script to control child scripts - sumanhyd - 07-14-2016

Hi All,

My requirement is that I have few use cases, each use case has 4-5 scripts for a specified browser, it can be for multiple browsers also. 

So now I need a driver script which typically checks for the use case execution status (Yes or NO) and browser type(IE,Chrome,IE+Chrome) and then executes the test scripts belongs to that Use Case. 

So now how to do the mapping between use case and browser type then run the scripts for different browsers.

Regards
Suman


RE: Driver Script to control child scripts - Ankesh - 07-26-2016

You can have One File that contains the Use cases and a flag whether to run the use case or not.
You can add multiple sheets to the same file where each sheet is the usecasename. These sheets would contain the scripts name related to each use case. Have another column for the browser. Multiple browsers should be separated by comma.

Hope the Below example would help.

MasterSheet: SHould contain the below column name
UseCaseName Execute
UC01 Y
UC02 N
UC03 Y

UC01 (UseCaseSheet):
ScriptName Execute Browser
UC01_TC01 Y IE
UC01_TC02 Y IE,Chrome