Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Table of Contents
stylenone

Required Robot + Webdriver Setup

  1. pip install robotframework

  2. pip install --upgrade robotframework-seleniumlibrary

  3. Install the browser driver and set it in PATH OR pip install webdrivermanager

Mapping Cases with AIO Tests

The below is just a sample test file, which opens Google and queries for a topic.

AIO Tests supports creating tests using the reports as well as mapping existing cases.

Mapping Existing AIO Tests to Automated Robot Tests

AIO Tests generates a unique key for each test created in AIO Test, for example, SCRUM-TC-1. To map an automated case to an existing AIO Test, the test name can take the test case key generated in its description. e.g.AT-TC-299: Login with existing user.

...

This would pull AT-TC-299 in the execution cycle and mark the result AT-TC-299 as passed i.e.”Login with existing user” against AT-TC-299.

Creating New Cases in AIO Tests from Automated Robot Tests

If no new key is specified in the spec, then new cases can be created using the results of the tests.

...

Info

AIO Tests key would still be generated of the format SCRUM-TC-xyz, which can then be added to the test name. This would ensure that changes to the description do not end up creating cases where new cases were not intended.

Configuration and Running ROBOT tests with the Junit option

Since Robot has added native support for JUnit, no new dependencies need to be added to generate the JUnit report. Tests can be triggered as below with the -x option and the name, that you would like for your results file

Code Block
 robot -x junitresult.xml tests/test1.robot 

Sample report file

The spec file runs and generates a test-output file under the results folder. A sample JUnit results file looks like below:

Code Block
<?xml version="1.0" encoding="UTF-8"?>
<testsuite tests="2" errors="0" name="Test1" skipped="0" time="16.137" failures="1">
<testcase classname="Test1" name="AT-TC-299 Login with existing user" time="5.228">
</testcase>
<testcase classname="Test1" name="Login with user not existing" time="10.713">
<failure message="Element 'id:displayName1' not visible after 5 seconds." type="AssertionError"></failure>
</testcase>
</testsuite>

Importing Results

Post execution of a JUnit suite, the TEST-<xxx>.xml file can be uploaded either via

...