cypress-xray-plugin
TypeScript icon, indicating that this package has built-in type declarations

8.5.0 • Public • Published

npm version npm downloads open GitHub issues unaddressed GitHub issues

Cypress Xray Plugin

A Cypress plugin for Xray integration. Supports Xray Server/DC and Xray Cloud.

Features include:

  • upload test results to Xray
    • attach screenshots as test execution evidence
    • attach web requests as test execution evidence
    • attach videos to test execution issues
    • reuse existing test execution and test plan issues
  • CI/CD ready
    • no hardcoded credentials
  • Cucumber integration
    • synchronization/upload of step definitions to Xray
    • results upload as described above

Quick Setup

Run the following command to add the plugin to your project:

npm install --save-dev cypress-xray-plugin

Then, configure the plugin in the Cypress project configuration:

import { configureXrayPlugin } from "cypress-xray-plugin";

export default defineConfig({
    e2e: {
        async setupNodeEvents(on, config) {
            await configureXrayPlugin(on, config, {
                jira: {
                    projectKey: "PRJ",
                    url: "https://example.org",
                },
            });
        },
    },
});

Make sure you also configure your credentials for Jira/Xray.

To have the plugin upload test results, link your test cases to Xray tests by specifying the corresponding issue keys in the test titles:

it("PRJ-42 My test", () => {
    // ...
});

[!NOTE] This plugin only works when running Cypress through the CLI (i.e. npx cypress run).

Documentation

Please visit the documentation to find out how to fully setup the plugin, including a full list of options.

Issues

If you're encountering strange behaviour or feel like a feature is missing, feel free to create a GitHub issue.

Further Reading

Here is a small list of related blog posts that may be of interest:

Versions

Current Tags

VersionDownloads (Last 7 Days)Tag
8.5.0
995latest

Version History

VersionDownloads (Last 7 Days)Published
8.5.0
995
8.4.1
535
8.4.0
2
8.3.2
58
8.3.1
439
8.3.0
1
8.2.3
5
8.2.2
1
8.2.1
6
8.2.0
1
8.1.0
104
8.0.0
1
7.5.0
867
7.4.2
211
7.4.1
35
7.4.0
2
7.3.0
150
7.2.0
2
7.1.0
988
7.0.1
14
7.0.0
2
6.0.0
2,933
5.2.245
5.2.1190
5.2.01
5.1.11
5.1.01
5.0.02
4.0.411
4.0.31
4.0.22
4.0.11
4.0.01
3.3.399
3.3.2101
3.3.113
3.3.01
3.2.01
3.1.01
3.0.12
3.0.01
2.0.424
2.0.37
2.0.25
2.0.12
2.0.01
1.1.18
1.1.01
1.0.32
1.0.21
1.0.11
1.0.01

Package Sidebar

Install

npm i cypress-xray-plugin

Weekly Downloads

7,880

Version

8.5.0

License

MIT

Unpacked Size

682 kB

Total Files

257

Last publish

Collaborators

  • qytera