Blog to understand automation concepts in QTP, Selenium Webdriver and Manual Testing concepts

How to execute multiple external tests action using LoadandrunAction from QTP test

In QTP, we can execute external tests actions from a QTP test using LoadandRunAction Method. This method was introduced Post QTP 10, and is very useful to execute multiple tests from a test.Using This method we can execute reusable actions.


Syntax for LoadandrunAction is:



LoadAndRunAction "C:\Documents\qtp\test", "Action1", oneIteration


This will load Action1 from test in the script in which it is called.

Benefits of LoadandRunAction  are as follows:


  • Loads Action from external test dynamically at run time.

  • Can be useful to execute multiple tests in batch from the driver script which will call multiple tests action using LoadandrunAction

  • To run a test from QC, Test Path starts with [QualityCenter] Subject followed by folder structure in QC e.g "[QualityCenter] Subject\TestAutomation/Module1/Test1"



No comments:

Post a Comment