Search code examples
cypressjirajira-xrayx-ray

Xray Cloud test execution status


Is there a way to obtain the status of every test (passed or failed) of a test execution using API REST in Xray Cloud?

I have a Jira Cloud with Xray where I import a Junit XML and I want to be able to get a file with the status of the test imported


Solution

  • For that purpose you need to use Xray Cloud's GraphQL API. Here are some code examples for that:

    You can actually use different GraphQL functions for that but the getTestExecutions may be the most appropriate one. You'll need to specify that you want the testRuns object on the results.