Report Grouping Commands
StartStepsGroup and StopStepsGroup
Description
These commands allow you to group steps together in order to make the report easier to read and work with.
Use StartStepsGroup
start a group of steps, and StopStepsGroup
to end it.
A typical use case for this is to run a test that includes both logging in and performing some actions post login. You can group the login flow and the subsequent flow in two different groups.
Example
info
Replace <server> with the appropriate URL.
- Public Continuous Testing Cloud - https://cloud.seetest.io/wd/hub/.
- Dedicated Continuous Testing Cloud environment - Your own domain. For example: https://company.experitest.com/wd/hub/
- On-premises Continuous Testing Cloud environment - Your designated URL. For example: https://company.com/wd/hub
Usage of Report Grouping Command
DesiredCapabilities dc = new DesiredCapabilities();
driver = new AndroidDriver(new URL("<server>"), dc);
seetest = new SeeTestClient(driver);
dc.setCapability(MobileCapabilityType.UDID, "deviceid");
...
...
seetest.startStepsGroup("Login Flow"); //start the login flow group
driver.findElement(By.xpath("//*[@id='usernameTextField']")).sendKeys("company");
driver.findElement(By.xpath("//*[@id='passwordTextField']")).sendKeys("company");
driver.findElement(By.xpath("//*[@id='loginButton']")).click();
driver.findElement(By.xpath("//*[@text='Login']")).click();
seetest.stopStepsGroup(); //stop the login flow group
seetest.startStepsGroup("Payment Flow"); //start the payment flow group
driver.findElement(By.xpath("//*[@text='Make Payment']")).click();
driver.findElement(By.xpath("//*[@id='phoneTextField']")).sendKeys("123456");
driver.findElement(By.xpath("//*[@id='nameTextField']")).sendKeys("Test");
driver.findElement(By.xpath("//*[@id='amount']")).click();
driver.findElement(By.xpath("//*[@id='countryTextField']")).sendKeys("US");
driver.findElement(By.xpath("//*[@text='Send Payment']")).click();
driver.findElement(By.xpath("//*[@text='Yes']")).click();
seetest.stopStepsGroup(); //stop the payment flow group
SetGroupStatus
Description
Use this to manually set the pass or fail status of the group.
Parameters
Name | Value | Description |
---|---|---|
status | String Allowed values: * Failed * Passed | Test status to set |
Example
info
Replace <server> with the appropriate URL.
- Public Continuous Testing Cloud - https://cloud.seetest.io/wd/hub/.
- Dedicated Continuous Testing Cloud environment - Your own domain. For example: https://company.experitest.com/wd/hub/
- On-premises Continuous Testing Cloud environment - Your designated URL. For example: https://company.com/wd/hub
Usage of Report Grouping Command
DesiredCapabilities dc = new DesiredCapabilities();
driver = new AndroidDriver(new URL("<server>"), dc);
seetest = new SeeTestClient(driver);
dc.setCapability(MobileCapabilityType.UDID, "deviceid");
...
...
seetest.startStepsGroup("Login Flow"); //start the login flow group
driver.findElement(By.xpath("//*[@id='usernameTextField']")).sendKeys("company");
driver.findElement(By.xpath("//*[@id='passwordTextField']")).sendKeys("company");
driver.findElement(By.xpath("//*[@id='loginButton']")).click();
driver.findElement(By.xpath("//*[@text='Login']")).click();
seetest.setGroupStatus("failed"); //set the steps group "Login Flow" to false status
seetest.stopStepsGroup(); //stop the login flow group