Squish is an UI automation tool. Here I wanted to apply filters to select test cases. Or execute test cases need a condition to be run.
Squish offers few ways to run test cases from command line and have some control over them.
To run a test suite from command line:
squishrunner --testsuite /home/MyProject/suite_UI
2.To run a particular test case/cases:
squishrunner --testsuite /home/reggie/suite_addressbook [--testcase test_case_name]*
Here you need to do some work. Let's say you want to categorise your tests between smoke test and Full Regression.
So you can use tags on top of scenarios. It quite easy. Example: @smoke Scenario: To connect to the device, start the emulator Given I am in the Start Screen When I Click on Manual connection option Then I should be able to connect to the device
@FullRegression
Scenario: To connect to the using using Manual connection option with connection type as Ethernet Only
Given Start Screen
When I Click on Manual connection option for Ethernet Connection
Then I should be able to connect to the sensor for Ethernet Only connection
To run all 'smoke' tags from a particular test case,
--testcase "tst_com_device_ManualConnect" --tags @smoke
You can skip one or many test cases,
----skip-testcase "tst_com_device_ManualConnect" --tags @smoke
All except the ones with @smoke tag will be run.