# TestRail

<div align="left"><img src="https://727226624-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-MjFmyReUsbJqDjHEAlW%2Fuploads%2FMBP6d4y678Yu1aobOUQi%2Ftestrail.png?alt=media&#x26;token=0b326edd-00c8-4294-a64d-b27747c011ed" alt=""></div>

## Set up

### Navigate to the Integration settings view

1. Select an app in the top left corner from the Switcher
2. Navigate to **App Settings** by clicking the gear icon (⚙️) at the top of the Timeline sidebar
3. Click on **Integrations** in the sidebar

### **Connect TestRail**

* Find the **TestRail** integration module under the **Regression testing** section
* Click the **Connect** button
* Enter your TestRail instance’s base URL, including the `https://` and excluding any trailing `/`
* Enter a TestRail API Key
  * You can generate API Keys within TestRail by going to **My Settings > API Keys > Add Key**

{% hint style="danger" %}
The API key creation flow in TestRail can be confusing. <mark style="background-color:red;">**Make sure you both generate**</mark><mark style="background-color:red;">**&#x20;**</mark>*<mark style="background-color:red;">**and**</mark>*<mark style="background-color:red;">**&#x20;**</mark><mark style="background-color:red;">**add the new API key, then click "Save Settings" (takes multiple separate clicks)**</mark><mark style="background-color:red;">.</mark> If you refresh the main TestRail API keys page (My Settings > API Keys) and the key you created doesn't appear, you missed a click!
{% endhint %}

* Click **Save**; you’ll be presented with a dialog in which to select your TestRail project and add any test run naming keywords

{% hint style="warning" %}
For the release linkage, Runway will parse your test run names for the presence of a version string (e.g. “**2.3.0**”)
{% endhint %}

{% hint style="info" %}
You can optionally add test run naming keywords (case insensitive) to associate test runs with a particular app, e.g. "iOS" or "Android"
{% endhint %}

For more information on how Runway will leverage TestRail, visit the [Regression testing step](https://docs.runway.team/using-runway/release-steps/regression-testing) article.
