I have XRAY integrated with Jenkins and our Jira instance following the documentation here I have no issues with XrayImportBuilder to import execution results or XrayExportBuilder to export scenarios from JIRA to run on jenkins.
When i use XrayImportFeatureBuilder to import scenarios into Jira, my .zip file remains empty and the import fails.
stage('Xray import feature files to Jira') {
steps {
step([$class : 'XrayImportFeatureBuilder',
serverInstance: automatedTestConstants.SERVER_INSTANCE,
projectKey : 'TEST',
folderPath : "${env.WORKSPACE}/${JOB_BASE_NAME}/src/test/resources/features"
])
}
}
the Jenkins trace shows
File: d:/JenkinsBuild/workspace/xxx/src/test/resources/features
File found: d:\JenkinsBuild\workspace\xxx\src\test\resources\features\xxx.feature
File found: d:\JenkinsBuild\workspace\xxx\src\test\resources\features\yyy.feature
Creating zip to import feature files. This may take a while if you have a big number of files.
File: d:/JenkinsBuild/workspace/xxx/src/test/resources/features
Waiting 10 seconds to finish the zip before making the request
{"testIssues":[],"preConditionIssues":[],"message":"Error parsing feature file\n"}
XRAY_IS_REQUEST_SUCCESSFUL: true
XRAY_RAW_RESPONSE: {"testIssues":[],"preConditionIssues":[],"message":"Error parsing feature file\n"}
XRAY_TESTS:
XRAY_ISSUES_MODIFIED:
XRAY_TEST_EXECS:
Temporary file: d:/JenkinsBuild/workspace/xxx/xray_cucumber_features.zip deleted
Response: (200) {"testIssues":[],"preConditionIssues":[],"message":"Error parsing feature file\n"}
Successfully imported Feature files
If i manually use the api to import a zip containing the same features, i get no errors.