Skip to content
Allure report logoAllure Report
Main Navigation ModulesDocumentationStarter Project

English

Español

English

Español

Appearance

Sidebar Navigation

Allure 3

Install & Upgrade

Install Allure

Upgrade Allure

Configure

Create Reports

How to generate a report

How to view a report

Improving readability of your test reports

Improving navigation in your test report

Reading Allure charts

Migrate from Allure 2

Allure 2

Install & Upgrade

Install for Windows

Install for macOS

Install for Linux

Install for Node.js

Upgrade Allure

Create Reports

How to generate a report

How to view a report

Improving readability of your test reports

Improving navigation in your test report

Features

Agent Mode

Test steps

Attachments

Test statuses

Assertion diffs

Sorting and filtering

Environments

Multistage Builds

Categories

Visual analytics

Test stability analysis

History and retries

Self-hosted storage

Quality Gate

Resolutions

Global Errors and Attachments

Timeline

Performance Metrics

Export to CSV

Export metrics

Guides

Migrating to Allure Java 3

JUnit 5 parametrization

JUnit 5 & Selenide: screenshots and attachments

JUnit 5 & Selenium: screenshots and attachments

Setting up JUnit 5 with GitHub Actions

Pytest parameterization

Pytest & Selenium: screenshots and attachments

Pytest & Playwright: screenshots and attachments

Pytest & Playwright: videos

Playwright parameterization

Publishing Reports to GitHub Pages

Deploying Self-Hosted Storage with Docker

Deploying Self-Hosted Storage on Cloudflare Workers

Allure Report 3: XCResults Reader

How it works

Overview

Glossary

Test result file

Container file

Categories file

Environment file

Executor file

History files

Test Identifiers

Integrations

Azure DevOps

Bamboo

GitHub Action

Gradle

Jenkins

JetBrains IDEs

Maven

Slack

TeamCity

Visual Studio Code

Xray

Frameworks

AVA

Getting started

Configuration

Reference

Axios

Getting started

Configuration

Reference

Behat

Getting started

Configuration

Reference

Behave

Getting started

Configuration

Reference

Bun

Getting started

Configuration

Reference

Chai

Getting started

Reference

Codeception

Getting started

Configuration

Reference

CodeceptJS

Getting started

Configuration

Reference

Cucumber.js

Getting started

Configuration

Reference

Cucumber-JVM

Getting started

Configuration

Reference

Cucumber.rb

Getting started

Configuration

Reference

Cypress

Getting started

Configuration

Reference

Dart and Flutter

Getting started

Configuration

Reference

Diesel

Getting started

Configuration

Reference

Fetch

Getting started

Configuration

Reference

Go

Getting started

Configuration

Reference

Jasmine

Getting started

Configuration

Reference

JBehave

Getting started

Configuration

Reference

Jest

Getting started

Configuration

Reference

JUnit 4

Getting started

Configuration

Reference

JUnit Jupiter

Getting started

Configuration

Reference

Mocha

Getting started

Configuration

Reference

Newman

Getting started

Configuration

Reference

Node.js Test Runner

Getting started

Configuration

Reference

NUnit

Getting started

Configuration

Reference

PHPUnit

Getting started

Configuration

Reference

Playwright

Getting started

Configuration

Reference

Playwright Java

Getting started

Configuration

Reference

pytest

Getting started

Configuration

Reference

Pytest-BDD

Getting started

Configuration

Reference

Reqnroll

Getting started

Configuration

Reference

Reqwest

Getting started

Configuration

Reference

REST Assured

Getting started

Configuration

Robot Framework

Getting started

Configuration

Reference

Rust Cargo Test

Getting started

Configuration

Reference

RSpec

Getting started

Configuration

Reference

Selenide

Getting started

Configuration

Reference

Selenium BiDi

Getting started

Configuration

Reference

SpecFlow

Getting started

Configuration

Reference

Spock

Getting started

Configuration

Reference

TestCafe

Getting started

Configuration

Reference

TestNG

Getting started

Configuration

Reference

Tinybench

Getting started

Reference

Vitest

Getting started

Configuration

Reference

WebdriverIO

Getting started

Configuration

Reference

xUnit.net

Getting started

Configuration

Reference

On this page

Xray integration Allure 3 ​

Allure Report 3 can update the statuses of test runs in Xray for Jira Server and Jira Data Center. Xray Cloud is not supported. The xray plugin that does this is included in the allure package.

For each test in the report that is linked to an Xray Test, Allure finds the test runs of this Xray Test in the Test Executions that you specify, and sets their status to PASS, FAIL or TODO. If the address of the report is known, it then adds a comment with a link to the report to each Test Execution.

The plugin doesn't create Tests, Test Executions or test runs, and doesn't import test results to Xray.

Prerequisites ​

  • Jira Server or Jira Data Center with the Xray app installed.
  • The Test Executions already exist and contain the Tests whose runs you want to update.
  • The Jira user, or the owner of the personal access token, can browse the Test Executions, edit their test runs, and add comments.

Link tests to Xray Tests ​

To link a test to an Xray Test, add a link of the tms type to the test, with the Jira key of the Xray Test as the link name, for example, XT-1. If the name is not a Jira key, Allure takes the first key from the link URL.

The link must have a URL: Allure Report 3 ignores links without one. In the Allure integrations for Java, a link added with @TmsLink gets a URL only if the TMS link pattern is configured, so set it in the allure.properties file:

properties
allure.link.tms.pattern=https://jira.example.com/browse/{}
java
@TmsLink("XT-1")
@Test
void shouldLogIn() {
    // ...
}

In other Allure integrations, see the documentation of your integration for how to add links.

If several test results are linked to the same Xray Test, for example, a parameterized test, Allure combines their statuses:

Results linked to the Xray TestStatus in Xray
At least one failed or brokenFAIL
At least one passed, none failed or brokenPASS
Only skipped or unknownTODO

For a test that was retried, only the latest attempt counts.

Configure the plugin ​

Add the xray plugin to the plugins section of the configuration file, next to the plugin of your report, and set the Jira address and the Test Executions to update:

javascript
import { defineConfig } from "allure";

export default defineConfig({
  plugins: {
    awesome: {},
    xray: {
      options: {
        endpoint: "https://jira.example.com",
        executions: ["XT-6", "XT-7"],
      },
    },
  },
});
json
{
  "plugins": {
    "awesome": {},
    "xray": {
      "options": {
        "endpoint": "https://jira.example.com",
        "executions": ["XT-6", "XT-7"]
      }
    }
  }
}
yaml
plugins:
  awesome: {}
  xray:
    options:
      endpoint: https://jira.example.com
      executions: [XT-6, XT-7]

With this configuration, after generating the report, Allure updates the test runs in the Test Executions XT-6 and XT-7 in Jira at https://jira.example.com. The credentials are not in the configuration file: Allure takes the personal access token from the ALLURE_XRAY_TOKEN environment variable, which you can set, for example, as a secret of your CI pipeline.

Allure updates only the test runs whose status differs from the result. Test runs of Xray Tests that no test in the report links to are left as they are.

Every option can also be provided via an environment variable. If an option is set in the configuration file, the environment variable is not used. The table below lists all the options.

Options ​

OptionEnvironment variableDescriptionDefault
endpointALLURE_XRAY_ENDPOINTJira address. Required
tokenALLURE_XRAY_TOKENJira personal access token. Required, unless username and password are set. If set, username and password are not used
usernameALLURE_XRAY_USERNAMEJira user name, used with password instead of a token
passwordALLURE_XRAY_PASSWORDJira password, used with username instead of a token
executionsALLURE_XRAY_EXECUTIONSKeys of the Test Executions to update. Required. In the environment variable, a comma-separated list, for example, XT-6,XT-7
statusesALLURE_XRAY_STATUS_<STATUS>Xray status to set for each Allure test status, see Change the status mappingDefault mapping
commentALLURE_XRAY_COMMENTWhether to add a comment with a link to the report, see Comment with a link to the reporttrue

Change the status mapping ​

By default, Allure sets these statuses in Xray:

Allure statusXray status
PassedPASS
FailedFAIL
BrokenFAIL
SkippedTODO
UnknownTODO

To change the mapping, set the statuses option. It only needs the statuses you want to change, the others keep their default mapping. For example, this configuration sets FAIL in Xray for skipped tests:

javascript
import { defineConfig } from "allure";

export default defineConfig({
  plugins: {
    awesome: {},
    xray: {
      options: {
        endpoint: "https://jira.example.com",
        executions: ["XT-6", "XT-7"],
        statuses: { skipped: "FAIL" },
      },
    },
  },
});
json
{
  "plugins": {
    "awesome": {},
    "xray": {
      "options": {
        "endpoint": "https://jira.example.com",
        "executions": ["XT-6", "XT-7"],
        "statuses": { "skipped": "FAIL" }
      }
    }
  }
}
yaml
plugins:
  awesome: {}
  xray:
    options:
      endpoint: https://jira.example.com
      executions: [XT-6, XT-7]
      statuses:
        skipped: FAIL

You can also use environment variables: ALLURE_XRAY_STATUS_PASSED, ALLURE_XRAY_STATUS_FAILED, ALLURE_XRAY_STATUS_BROKEN, ALLURE_XRAY_STATUS_SKIPPED and ALLURE_XRAY_STATUS_UNKNOWN, for example, ALLURE_XRAY_STATUS_SKIPPED=FAIL.

Only the PASS, FAIL and TODO statuses are supported.

Comment with a link to the report ​

After updating the test runs of a Test Execution, Allure adds a comment with a link to the report to the Test Execution. The comment is added only if the address of the report is known, for example, from historyBaseUrl, and only if all test runs of the Test Execution were read and updated successfully.

The comment is added on every report generation. To turn it off, set comment: false or ALLURE_XRAY_COMMENT=false.

Troubleshooting ​

If a request to Jira fails, Allure prints the error to the console and continues with the next request. The report is generated anyway. For example:

plain
[Allure Xray Plugin] failed to read test runs of XT-7: Request failed with status code 404 (HTTP 404)

An HTTP 401 or 403 error usually means missing credentials or permissions.

If the Jira address, the credentials or the Test Executions are not set, or a status in the mapping is not supported, Allure prints an error and doesn't update anything.

If a test run isn't updated, check that:

  • the test has a link of the tms type with a URL;
  • the link name, or the link URL, contains the key of the Xray Test;
  • one of the Test Executions contains a test run of this Xray Test.
Pager
Previous pageVisual Studio Code
Next pageFrameworks
Powered by

Subscribe to our newsletter

Get product news you actually need, no spam.

Subscribe
Allure TestOps
  • Overview
  • Why choose us
  • Cloud
  • Self-hosted
  • Success Stories
Company
  • Documentation
  • Blog
  • About us
  • Contact
  • Events
© 2026 Qameta Software Inc. All rights reserved.
A Markdown version of this page is available at /docs/integrations-xray.md