Hello there,
I'm trying to import cucumber json to Jira (X-ray), but I'm facing few difficulties. I've included the specifics below.
I have tried two api's of both 1.0 and 2.0 versions, according to below documentation
https://docs.getxray.app/display/XRAY30/Import+Execution+Results+-+REST#ImportExecutionResultsREST-CucumberJSONresultsMultipart
https://docs.getxray.app/display/XRAY/Import+Execution+Results+-+REST
/rest/raven/2.0/import/execution/cucumber?testExecKey=IRx67-90--header 'Authorization: Bearer xxxxx'
POST /rest/raven/2.0/import/execution/cucumber/multipart?testExecKey=IRx67-90 HTTP/1.1 Authorization: Bearer OTc5MjY1MTYyMDM4OhLblTGVdp445xBbKMNxxxxxxJ Content-Type: multipart/form-data; boundary=--011000010111000001101001 Host: jira.dt.renault.com Content-Length: 405 -----011000010111000001101001 Content-Disposition: form-data; name="result" C:\Downloads\bdd_report-master\bdd_report-master\POC\POC\cucumber-json\LockStatus.json -----011000010111000001101001 Content-Disposition: form-data; name="info" Downloads\bdd_report-master\bdd_report-master\POC\POC\cucumber-json\testExecutionInfo2.json -----011000010111000001101001-
I'm receiving this response"error": "Error assembling issue data: project is required" while hitting above api's.
info:
{ "fields": { "project": { "id": "IR7" }, "summary": "Test Execution for cucumber Execution", "issuetype": { "id": "10212" } } }
I'm not with xray, but you mention you are on Cloud, but the links you are providing is to old archived, deprecated options and its voor on-prem installations of Jira.
Please look at the Xray cloud documentation: https://docs.getxray.app/display/XRAYCLOUD/REST+API
Hi @Hari Venkadesh ,
Welcome to the community!
If possible go through the documentation as @Marc - Devoteam shared, if you have questions please reach out to our support: https://jira.getxray.app/servicedesk/customer/portal/2
Best, Francisco.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi @Francisco Fonseca _Xray_ ,
After hitting this /rest/raven/2.0/import/execution/cucumber/multipart? api with below ~info and ~AI_sample cucumber json - it creates test execution but cucumber testcases are not mapped to the test execution, I also tried to import it manually (import Execution results ) no testcases mapped to the testexecution, I am not sure how to validate cucumber and what I missed here
info:
{
"fields": {
"project": {
"key": "IXXXX"
},
"summary": "Test Execution for cucumber Execution",
"description": "For more info please check [here|https://www.example.com]",
"issuetype": {
"id": "10009"
}
}
}
AI_sample cucumber json:
[
{
"uri": "features/Login.feature",
"elements": [
{
"name": "Successful login with valid credentials",
"id": "successful-login-with-valid-credentials",
"steps": [
{
"name": "I navigate to the login page",
"keyword": "Given ",
"result": {
"status": "passed"
}
},
{
"name": "I enter valid credentials",
"keyword": "When ",
"result": {
"status": "passed"
}
},
{
"name": "I am redirected to the dashboard",
"keyword": "Then ",
"result": {
"status": "passed"
}
}
]
},
{
"name": "Unsuccessful login with invalid credentials",
"id": "unsuccessful-login-with-invalid-credentials",
"steps": [
{
"name": "I navigate to the login page",
"keyword": "Given ",
"result": {
"status": "passed"
}
},
{
"name": "I enter invalid credentials",
"keyword": "When ",
"result": {
"status": "failed",
"error_message": "Invalid username or password"
}
},
{
"name": "I see an error message",
"keyword": "Then ",
"result": {
"status": "passed"
}
}
]
}
]
},
{
"uri": "features/Account.feature",
"elements": [
{
"name": "Creating a new account",
"id": "creating-a-new-account",
"steps": [
{
"name": "I navigate to the account creation page",
"keyword": "Given ",
"result": {
"status": "passed"
}
},
{
"name": "I enter all required details",
"keyword": "When ",
"result": {
"status": "passed"
}
},
{
"name": "I successfully create a new account",
"keyword": "Then ",
"result": {
"status": "passed"
}
}
]
}
]
}
]
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.