---
title: "Exporting a Test Plan"
canonical: "https://docs.getxporter.app/space/XPORTER/1412423/Exporting%20a%20Test%20Plan"
format: markdown
---
> Macro (rw-ui-expands-macro)
> 
> > Macro (rw-expand)
> 
> > Macro (toc)

## <span style="color: #172B4D">Introduction</span>

<span style="color: #172B4D">Xporter for Jira allows you to get the following data from the Xray Test Plan.</span>

## Usage

### Overall Execution Status

Export the Overall Execution Status with the name and percentage for each Test Plan Status, using this placeholder: `${Overall Execution Status}`

You can print the status of the Test Execution by using this notation:

| **% per Status** | **Number of Tests per Status** |
| --- | --- |
| ${Overall Execution Status.NameOfStatus} | ${Overall Execution Status.NameOfStatus.Count} |

Example:

```
Todo: ${Overall Execution Status.TODO}% (Overall Execution Status.TODO.Count})
Fail: ${Overall Execution Status.FAIL}% (Overall Execution Status.FAIL.Count})
Pass: ${Overall Execution Status.PASS}% (Overall Execution Status.PASS.Count})
Executing: ${Overall Execution Status.EXECUTING}% (Overall Execution Status.EXECUTING.Count})
Aborted: ${Overall Execution Status.ABORTED}% (Overall Execution Status.ABORTED.Count})
```

### Iterating over Tests

Since it is not known in advance how many Tests exist in a Test Plan, this notation allows iterating a section over all the Tests of a Test Plan:

```
#{for tests}
	Content and Test Mappings.	Example: ${Tests[n].Key}
#{end}
```

or

```
#{for j=TestsCount}
	Content and Test Mappings.	Example: ${Tests[j].Summary}
#{end}
```

*n* is the index of Test, starting from 0. The field **TestsCount** was created to give the total number of Tests.

[Here you can print Jira native data or print Xray specific data](https://docs.getxray.app/display/XRAY/Exporting+a+Test) such as the Steps of the test.

## Iterating over Test Execution

Since it is not known in advance how many Tests exist in a Test Plan, this notation allows iterating a section over all the Tests of a Test Plan:

```
#{for testExecutions}
	Content and Test Mappings.	Example: ${TestExecutions[n].Key}
#{end}
```

or

```
#{for j=TestExecutionsCount}
	Content and Test Mappings.	Example: ${TestExecutions[j].Summary}
#{end}
```

*n* is the index of TestExecution, starting from 0. The field **TestExecutionsCount** was created to give the total number of TestExecutions.

[Here you can print Jira native data or print Xray-specific data](https://docs.getxray.app/display/XRAY/Exporting+a+Test+Execution) such as the list of the Test executed inside of the Test Runs and their status.

<details>
<summary>Support/Troubleshooting</summary>

If you have questions or technical issues, please [contact the Support team via the Customer Portal (Jira service management)](https://jira.getxray.app/servicedesk/customer/portal/2/user/login?destination=portal%2F2%2Fcreate%2F28) or [send us a message using the in-app chat](https://docs.getxporter.app/space/XPORTER/23102936).
</details>