I’m having trouble with Jira Xray integration. When I use the /rest/raven/2.0/import/execution/cucumber/multipart?
endpoint to upload my cucumber test results, the test execution gets created successfully but none of my test cases show up in it. I’ve also tried doing the import manually through the UI using “Import Execution Results” but same issue happens.
I’m not sure what’s wrong with my cucumber JSON format or if I’m missing something in the configuration. Has anyone faced this before?
My project info:
{
"fields": {
"project": {
"key": "MYPROJ"
},
"summary": "Automated Test Run Results",
"description": "Cucumber test execution import",
"issuetype": {
"id": "10009"
}
}
}
Sample cucumber JSON:
[
{
"uri": "features/UserAuth.feature",
"elements": [
{
"name": "User can sign in with correct details",
"id": "user-can-sign-in-with-correct-details",
"steps": [
{
"name": "user opens the signin form",
"keyword": "Given ",
"result": {
"status": "passed"
}
},
{
"name": "user provides correct username and password",
"keyword": "When ",
"result": {
"status": "passed"
}
},
{
"name": "user should see the home screen",
"keyword": "Then ",
"result": {
"status": "passed"
}
}
]
},
{
"name": "User cannot sign in with wrong details",
"id": "user-cannot-sign-in-with-wrong-details",
"steps": [
{
"name": "user opens the signin form",
"keyword": "Given ",
"result": {
"status": "passed"
}
},
{
"name": "user provides incorrect credentials",
"keyword": "When ",
"result": {
"status": "failed",
"errormessage": "Authentication failed"
}
},
{
"name": "user should see error notification",
"keyword": "Then ",
"result": {
"status": "passed"
}
}
]
}
]
}
]