# Setup FAQ for Delegate for Testing

> Solutions for common Delegate for Testing setup issues, including expired CLI tokens and Test Manager data visibility when switching UiPath accounts.

This page answers common questions that come up after completing the one-time setup in [Setting up and running your first test case](installing-delegate-for-the-testing-profile.md), which covers installing and authenticating the UiPath Command Line Interface (CLI).

## Setup checklist: what needs to happen once

| Step | What to do | One-time? |
| --- | --- | --- |
| 1 | Select the QA/Testing persona | Yes |
| 2 | Install the `uip` CLI | Yes |
| 3 | Run `uip login` | Yes (re-authenticate if the token expires) |
| 4 | Know your project key | Yes, per project |
| 5 | Ask **Delegate** to run a test case | Every time |

## What Delegate does not require you to set up separately

* No separate Test Manager login — your identity (display name and email) comes automatically from your UiPath Cloud session; `uip login` is still required so the CLI can execute tests and publish results.
* No browser setup — **Delegate** uses Chrome automatically.
* No configuration files — the **Test Cloud** plugin handles everything.
* No Orchestrator connection for test execution — all runs happen locally via the CLI.

## Authentication fails with "Authentication failed" or "401 Unauthorized"

This happens when your `uip` CLI token has expired. Tokens typically expire after a period of inactivity, and there is no warning before expiry, so this error message is your first signal.

To fix it:

1. Run `uip login`.
2. Sign in with your UiPath account in the browser window that opens.

The token refreshes automatically — no settings changes are needed in **Delegate**. The fix takes about 30 seconds, and everything else (project keys, Test Manager setup) stays intact; only the auth token needs refreshing.

## Test Manager data when switching accounts

Your Test Manager data lives in UiPath cloud, tied to your organization and tenant, not to your personal account credentials. Switching accounts affects access, not the data itself.

| Aspect | Switch to a different account (same org/tenant) | Switch to a completely different org/tenant |
| --- | --- | --- |
| Test cases, test sets, executions | Still there — data is org-level | Not visible — different org |
| Results Delegate published | Still there | Not visible |
| AutonomousExecution labels | Still there | Not visible |
| Delegate's CLI login | Needs `uip login` with the new account | Needs `uip login` with the new account |
| Delegate's Test Manager identity | Updates automatically when you switch your UiPath Cloud session account | Updates automatically when you switch your UiPath Cloud session account |

If you are moving to a new UiPath organization (for example, switching employers, or moving from a trial tenant to a production tenant), your historical test data does not follow you. It stays in the original org, and you start fresh in the new tenant.

If you are just switching which personal account you use within the same organization, all your data remains accessible. Sign in to the new account in your UiPath Cloud session so **Delegate** picks up the updated identity, then run `uip login` again so the CLI can execute and publish under that account.
