Back to QMetry All Products Help Page
How to execute single or a batch of specific .bdd file in a one test run?
QAS supports multiple types of scenario execution with the help of the QAF framework. Kindly refer to the given below scenario for .bdd file execution.
Scenario 1:
If a user wants to execute some list of tests which are in the same folder but don't want to modify the web_config.xml.
Step 1: Create a new XML file in config directory (like MyTest_config.xml ) and paste web_config.xml code in that XML file.
Step 2 : Update the value path of parameter tag up to that particular folder location like :
<parameter name="scenario.file.loc" value="scenarios/web/myFolder"></parameter>
Step 3: Add this XML file name(MyTest_config.xml) in pom.xml in place of web_config.xml name at testSuiteFile tag to make it executable.
Scenario 2:
If a user wants to execute some specific list of tests from different-different folders but doesn't want to modify the web_config.xml for this change.
Step 1: update groups tag (like RUN1) in META-DATA option of each SCENARIO which you want to execute
Step 2: Create a new XML file in config directory (like:group_config.xml) and paste web_config.xml code in that XML file.
Step 3: Add a groups tag inside test tag where our group name (Run1) will be defined inside include tag like :
Step 4: Add this XML file name(MyTest_config.xml) in pom.xml in place of web_config.xml name at testSuiteFile tag to make it executable.
Scenario 3:
If a user simply wants to select some test case to execute and the rest of them should not be executed.
Answer: Just open your test case and add an enabled tag with value True or False inside META-DATA option like :
META-DATA: {"description":"Sample Test Scenario","groups":"Run1"],"author":"kumar.shanu",enabled=True}
It will execute the only SCENARIO which will have enabled=True in MATA-DATA option and will reject the SCENARIO having enabled=False.
In this case no need to update existing XML files.
Back to QMetry All Products Help Page