Nexial Automation

Test Automation Platform for everyone!

X

Test Rail Setup

Overview

TestRail is a test case and test management software tool that helps teams to manage and track their software testing efforts. TestRail enables you to create, manage, and organize test cases and suites within an optimized user interface and application structure. For more details, please walk through TestRail Documentation

HOW to import Testcases in TestRail

Importing testcases to TestRail includes following steps:-

  1. Prerequisite configuration of TestRail account to access suites using its APIs.
  2. Configure Nexial Data Variables to access TestRail through apis.
  3. Configure project meta file to access required TestRail project.
  4. Import testcases using Nexial batch file nexial-tms-importer

Prerequisite Configuration of TestRail:-
User need to configure TestRail account to access it through APIs.

  • Firstly, TestRail project in which test cases to be imported should use multiple suites to manage test cases.
  • Admin must enable API to allow access through APIs. To activate, go to ADMINISTRATION => Site Settings => API.

Configure Using Data Variables:-

  • nexial.tms.source: User should specify tms source tool to import testcases. In this case, it must be testrail.
  • nexial.tms.url: URL which consists of organization name in it. e.g. https://<organization>.testrail.io/.
  • nexial.tms.username: Username/Email Id used to log in to TestRail account.
  • nexial.tms.password: Password used to log in to TestRail account.
# values are for testrail for reference except source name
nexial.tms.source=testrail
nexial.tms.url=https://TestRailOrganization.testrail.io/
nexial.tms.username=xyz@gmail.com
nexial.tms.password=testrailPassword

User needs to provide above credentials to access testrail through Nexial variables using one-time setup, you can provide TestRail integration configuration details once and build setup.jar using nexial-setup.cmd or nexial-setup.sh.

Configure Project Meta File:-
Configure project.tms.json file in the .meta folder of project whose script to be imported. This json requires projectId from the TMS tool where the scripts to be imported. projectId can also be project name depending on provided tms tool.

Import Testcases:-
Test cases of the project are to be imported using Nexial batch file nexial-tms-importer After importing testcases to tms tool, project.tms.json json file will be automatically updated with imported test case data like below. This json is for script file import for reference only.

For example, project.tms.json should look like this after import,

Note : projectId must be project id in the TestRail which can be seen in the URL once you open the TestRail project.

See Also