> For the complete documentation index, see [llms.txt](https://docs.qyrus.com/web-testing/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.qyrus.com/web-testing/build/projectsetup.md).

# Project Setup

Project Setup is where you configure the things your tests rely on: database connections, the browser recorder, reusable variables, integrations, run presets and functions. Set these up once and every test in the project can use them.

Six sections are available:

* [**Database Configuration**](#database-configuration) — connect to a database so your test steps can pull data from it with the **Execute Query** action.
* [**Qyrus Recorder**](#qyrus-recorder) — the Chrome extension that records test steps as you click through your application.
* [**Global Variable**](#global-variable) — values you create once and reuse across every test script in the project, grouped into environments.
* [**Integrations**](#integrations) — connect Qyrus to tools such as Jira so you can raise tickets from a test report.
* [**Run Configuration**](#run-configuration) — save a browser, database, variable and resolution combination as a preset, then reuse it whenever you run a test.
* [**Functions**](#functions) — reusable blocks of steps you can import into any script.

## Prerequisites

* A project. See [Creating a Project](/web-testing/project-creation/create-project.md).
* For **Database Configuration**, the connection details for a database you are allowed to use.
* For **Qyrus Recorder**, the Chrome browser.

## Opening Project Setup

1. Open your project.
2. Click the **Project Setup** tile.

   ![Project Setup tile](https://239974709-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FycS61vFhJMvvtnJCrDJk%2Fuploads%2Fgit-blob-9ecddca5052c641dffeae65fb24996f6c30b2644%2Fbuild-projectsetup-01.png?alt=media)
3. The six sections are listed down the left.

   ![Project Setup sections](https://239974709-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FycS61vFhJMvvtnJCrDJk%2Fuploads%2Fgit-blob-13e41bd590fdb1461ac33bae35f019248534cf50%2Fbuild-projectsetup-02.png?alt=media)

You can also reach any section from the **Setup** menu in the top bar.

![Setup menu](https://239974709-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FycS61vFhJMvvtnJCrDJk%2Fuploads%2Fgit-blob-8edd9403c1b81b22f513d9c6d398f3c3b8e13bb9%2Fbuild-projectsetup-12.png?alt=media)

A red **Data Use Notice** sits above every Project Setup screen: "Do not enter production or sensitive data. Use only non-confidential, synthetic or anonymized data". Take it seriously — this is a testing platform, not a vault.

***

## Database Configuration

Connect a database to the project so test steps can read data from it at run time.

1. In Project Setup, click **Database Configuration**.
2. Click **New Configuration**.
3. Fill in the connection details.

   ![Database configuration form](https://239974709-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FycS61vFhJMvvtnJCrDJk%2Fuploads%2Fgit-blob-879595f381f691fc4317cf900dde79bd8e03c8d3%2Fbuild-projectsetup-03.png?alt=media)

   | Field                      | What to enter                               |
   | -------------------------- | ------------------------------------------- |
   | **New Configuration Name** | A name you will recognise later             |
   | **Choose Database Type**   | **MySQL**, **PostgreSQL** or **SQL Server** |
   | **Host Name**              | The server address                          |
   | **Port Number**            | The port the database listens on            |
   | **Database Name**          | The database to connect to                  |
   | **User Name**              | The account used to connect                 |
   | **Password**               | That account's password                     |
4. Click **Save Configuration**.

Saved configurations are listed under **Database Configuration**, where you can edit or delete them.

***

## Qyrus Recorder

Qyrus Recorder is a Chrome extension. Install it and you can record your clicks and typing on a web application, then turn them into test steps instead of writing each step by hand.

![Qyrus Recorder](https://239974709-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FycS61vFhJMvvtnJCrDJk%2Fuploads%2Fgit-blob-e5427c0e344962ebcf37e2acdc6c640a6a44bbe5%2Fbuild-projectsetup-04.png?alt=media)

1. In Project Setup, click **Qyrus Recorder**.
2. Click the link to add the extension from the Chrome Web Store to your Chrome browser.
3. For instructions on using it, follow the **confluence page** link on the same screen.

***

## Global Variable

Global variables are values you define once and reuse in any test script in the project — a login name, a base URL, a search term. Change the value in one place and every script that uses it picks up the change.

Variables are grouped into **environments**, so you can hold one set of values for staging and another for production-like testing, and switch between them at run time.

![Global Variable](https://239974709-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FycS61vFhJMvvtnJCrDJk%2Fuploads%2Fgit-blob-050cafc696e14e817076629bb5346b1bea666401%2Fbuild-projectsetup-05.png?alt=media)

The left menu calls this section **Global Variable**. The **Setup** menu in the top bar calls it **Global Variables**. They are the same screen.

### Creating a global variable

1. In Project Setup, click **Global Variable**.
2. Choose the environment you want to add the variable to. New projects start with **Global**.
3. Click **New Variable**. A new row appears.

   ![New variable row](https://239974709-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FycS61vFhJMvvtnJCrDJk%2Fuploads%2Fgit-blob-1c655ead6dc9e236e96dcfb0e5ce8c6e1aaf0325%2Fbuild-projectsetup-06.png?alt=media)
4. Enter a **Variable Name**.
5. Choose the variable type from the dropdown. **Custom** is the default.
6. Enter the value in **Enter value**. Some types ask for a format or a range instead.
7. Click the save button above the list.

Use **Search Variables** to find a variable in a long list.

### Working with environments

Four buttons sit next to the environment dropdown:

| Button                 | What it does                                                       |
| ---------------------- | ------------------------------------------------------------------ |
| **Create Environment** | Adds a new environment. Enter a name and click **Create**.         |
| **Clone**              | Copies the variables of the selected environment into another one. |
| **Edit Environment**   | Renames the selected environment.                                  |
| **Delete Environment** | Removes the selected environment.                                  |

Cloning **replaces** the target environment's variables with those of the environment you are copying from. Check which environment you have selected before you confirm.

### Types of variable

| Type               | What it produces                                                                                                                        |
| ------------------ | --------------------------------------------------------------------------------------------------------------------------------------- |
| **Custom**         | A value you type yourself.                                                                                                              |
| **Integer**        | A random whole number. Give a minimum and a maximum.                                                                                    |
| **Decimal**        | A random decimal. Give the number of decimal places.                                                                                    |
| **UUID/GUID**      | A new unique identifier each run.                                                                                                       |
| **Email**          | An email address, either yours or a random one in the form `???????##@gmail.com`, where `?` is a random letter and `#` a random number. |
| **Date**           | A random date in a format you choose. See [Date formats](#date-formats).                                                                |
| **BaseURL**        | A URL you use often across tests.                                                                                                       |
| **FirstName**      | A random first name.                                                                                                                    |
| **LastName**       | A random last name.                                                                                                                     |
| **PastDate**       | A random date in the past. Give a minimum year and a format.                                                                            |
| **FutureDate**     | A random date in the future. Give a maximum year and a format.                                                                          |
| **File**           | A file you upload once and reuse across the project.                                                                                    |
| **Password**       | A password, masked wherever it appears. See [Password variables](#password-variables).                                                  |
| **PersistentUUID** | A unique identifier. This type has no value field — Qyrus supplies the value.                                                           |
| **Protected**      | A value you type, hidden as you type it.                                                                                                |

### Date formats

Specify the date and time format you want. The default is `dd-MM-yyyy`. Note that `MM` means months and `mm` means minutes. For example, `yyyy-MM-dd HH:mm:ss` produces something like `2020-01-16 03:25:12`.

| Format                    | Example                 |
| ------------------------- | ----------------------- |
| dd-MM-yyyy / MM-dd-yyyy   | 25-06-2020 / 06-25-2020 |
| dd-MM-yyyy HH:flag\_mm:ss | 25-06-2020 06:07:59     |
| dd MMMM yyyy              | 06 July 2020            |

Choosing **Date** adds two fields to the row: the format, and **Modify Date**.

![A Date variable, with its format and Modify Date](https://239974709-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FycS61vFhJMvvtnJCrDJk%2Fuploads%2Fgit-blob-0cab52b1bc5fad2cb6e40496650837abd7fb26a8%2Fbuild-projectsetup-13.png?alt=media)

**Modify Date** shifts the generated date by a number of days, months or years.

Enter it as `day/month/year`, each with a `+` or `-`. For example, with a format of `dd-MM-yyyy` and a **Modify Date** of `+1/+10/-1`, Qyrus takes the generated date, subtracts one year, adds ten months, then adds one day — year first, then months, then days.

Another example:

* Format: `dd-MM-yyyy`
* Date generated: 08/09/1997
* Modify Date: `+1/+2/-2`
* Final value: 09/11/1995

Adding to a date can roll it into the next month or year: 09/12/2021 with `+1` on months becomes 09/01/2022, and 31/12/2021 with `+1` on days becomes 01/01/2022.

Leave the field blank to change nothing. To change only one part, put `0` in the others — for example `0/+1/0` for months only, or `-10/0/+1` for the day and year only.

### Password variables

Any variable of type **Password** is masked with `******` on the script page and in every report, regardless of how long the password actually is.

* Toggling mask or unmask on the steps page does not change reports. Password data is always masked there.
* If a password variable is used in a verifier and the step **passes**, the Actual Output, Expected Output and Data fields are all masked.
* If a password variable is used in a verifier and the step **fails**, Expected Output and Data are masked but Actual Output is shown unmasked.
* Masking does not apply to data handlers. The Data column shows the value stored by the **Create Variable** action, which is always the original.
* Other action types capture Actual Output in reports, and that output is not masked even when a password variable was used in the input field.

### Using a global variable in a test step

1. Open a test script.
2. Add or edit a step, and in the **Data** field type the variable name wrapped in `#` characters — for example `#Statement_Date#` or `#Customer_Email#`.
3. Save the script.

![A step using a global variable in its Data field](https://239974709-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FycS61vFhJMvvtnJCrDJk%2Fuploads%2Fgit-blob-f539ec54674004a289416f1f5791bab75fea2b01%2Fbuild-projectsetup-14.png?alt=media)

To see which variables are available while editing a script, open the right-hand panel and choose the **Global Variable** tab, then pick the environment.

Global variable values used during a run appear in the report:

![Global variables in a report](https://239974709-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FycS61vFhJMvvtnJCrDJk%2Fuploads%2Fgit-blob-2a5f60f5b912c1df79d696c60e59e8c4bcafb9e6%2Fglobalsamplevariable.png?alt=media)

***

## Integrations

Integrations connect Qyrus to tools such as Jira, so you can raise a ticket straight from a test report.

![Integrations](https://239974709-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FycS61vFhJMvvtnJCrDJk%2Fuploads%2Fgit-blob-4598308f836803ea04e1606c0548b3a975db850a%2Fbuild-projectsetup-07.png?alt=media)

Integrations are no longer configured inside the project. The screen now shows:

"**Important Update:** Manage all your integrations in one place. Click Add Configuration to view and configure integrations."

1. In Project Setup, click **Integrations**.
2. Click **Add Configuration**. Qyrus opens the central integrations page, outside Web Testing, where all your integrations for every service are managed together.

Once an integration is configured, you can raise tickets from the **Sprint Reports** and **Test Lab Reports** screens using **Create Ticket** on an execution row.

***

## Run Configuration

A run configuration is a saved preset: the browsers, database, environment variables, healing option, screen resolution and result sharing you want, bundled under a name. Pick it at run time instead of setting the same options again every time.

1. In Project Setup, click **Run Configuration**.
2. Click **New Configuration**.

   ![Run Configuration](https://239974709-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FycS61vFhJMvvtnJCrDJk%2Fuploads%2Fgit-blob-5723ee41bea9650d2ddd1af90c59d9d9b0da7ecf%2Fbuild-projectsetup-08.png?alt=media)
3. Fill in the seven sections.

   ![New run configuration, sections 1 and 2](https://239974709-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FycS61vFhJMvvtnJCrDJk%2Fuploads%2Fgit-blob-a6448ff9ca189c3f5c55625e59b439cae739c94b%2Fbuild-projectsetup-09.png?alt=media)

   | # | Section                  | What to do                                                                                                                                |
   | - | ------------------------ | ----------------------------------------------------------------------------------------------------------------------------------------- |
   | 1 | **Preset Name**          | Enter a **Run Configuration Name**. Required.                                                                                             |
   | 2 | **Browser Selection**    | Choose a **Platform**, then tick the **Browsers** to run on. Chrome entries also offer a **Select Device** dropdown for mobile emulation. |
   | 3 | **Database**             | Optional. Pick one of your saved database configurations.                                                                                 |
   | 4 | **Environment Variable** | Optional. Pick the environment whose global variables the run should use. Defaults to **Global**.                                         |
   | 5 | **Healer**               | Optional. Turn on **Activate Healer** to let Qyrus repair locators that have changed.                                                     |
   | 6 | **Screen Resolution**    | Optional. Defaults to **1024x768**.                                                                                                       |
   | 7 | **Share Results**        | Add the email addresses that should receive the result.                                                                                   |

   ![New run configuration, sections 3 to 7](https://239974709-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FycS61vFhJMvvtnJCrDJk%2Fuploads%2Fgit-blob-d3960f2df095ad3d5d2cae324b92c88755bf02dd%2Fbuild-projectsetup-10.png?alt=media)
4. Click **Save Configuration**.

Saved presets are listed under **Run Configuration**, where you can edit them, delete them or set one as the default.

A note on the browser list: "If selected tests exceed available concurrency, they queue; delays or timeouts occur only if over 30 minutes."

### Using a run configuration

On any run screen, turn on **Run with configuration**, then choose your preset from the dropdown. The preset's settings appear in the summary panel on the right so you can check them before running.

***

## Functions

A function is a group of steps saved together so you can import them into any script instead of rebuilding the same sequence each time.

![Functions](https://239974709-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FycS61vFhJMvvtnJCrDJk%2Fuploads%2Fgit-blob-b85f56cd0263757ec85cb900162ee67f240fb380%2Fbuild-projectsetup-11.png?alt=media)

1. In Project Setup, click **Functions**.
2. Functions already created in the project are listed here.
3. Use **Import Function** to bring in a function file, and **Update Function** to replace one.

See [Functions](/web-testing/advanced-features/functions.md) for how to create and use them.
