Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

Earn badges and make progress

You're on your way to the next level! Join the Kudos program to earn points and save your progress.

Deleted user Avatar
Deleted user

Level 1: Seed

25 / 150 points

Next: Root


1 badge earned


Participate in fun challenges

Challenges come and go, but your rewards stay with you. Do more to earn more!


Gift kudos to your peers

What goes around comes around! Share the love by gifting kudos to your peers.


Rise up in the ranks

Keep earning points to reach the top of the leaderboard. It resets every quarter so you always have a chance!


Come for the products,
stay for the community

The Atlassian Community can help you and your team get more value out of Atlassian products and practices.

Atlassian Community about banner
Community Members
Community Events
Community Groups

X-ray JUnit XML Multipart is not accepting mutiple xml files

Akshatha Ramesh
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
May 22, 2023

sample_test1.feature -

Feature: Sample feature1
    Scenario: Testing1
        When the Component is a TEST

    Scenario: Testing2
        When the Component is a TEST

sample_test2.feature -

Feature: Sample feature2

    Scenario: Testing3
        When the Component is a TEST

Radish command -

radish --cucumber-json=sample_test.json --junit-xml=xmlreport/sample_test1.xml sample_test1.feature -b test/
radish --cucumber-json=sample2_test.json --junit-xml=xmlreport/sample_test2.xml sample_test2.feature -b test/

the output of the above command will create two XML files:

ls xmlreport/

I have a stage in Jenkins - which does this -

    stage('Import results to Xray') {
    steps {
        step([$class: 'XrayImportBuilder', endpointName: '/junit/multipart', importFilePath: 'xmlreport/*.xml', credentialId: "${JIRA_USER_ID}", projectKey: 'TEST', serverInstance: '<myserver>', testEnvironments: 'TEST', importToSameExecution: "true", importInParallel: "false", importInfo: 'Jenkins/XrayTestExecutionImportInfo.json', testImportInfo: 'Jenkins/XrayTestImportInfo.json', inputInfoSwitcher: 'filePath', inputTestInfoSwitcher: 'filePath' ])        

XrayTestImportInfo.json :

    "fields": {
    "description": "Automated Test",  
        "labels": [

Output of Jenkins Console:

Successfully imported JUnit XML multipart results from sample_test1.xml
Successfully imported JUnit XML results from sample_test2.xml

I see that all the jira IDs present in sample_test1.xml (jiraID-123,jiraID-456) are updated with the contents in XrayTestImportInfo.json. But, the jira IDs in sample_test2.xml (jiraID-789) do not get updated.


I have also tried:

curl -H "Content-Type: multipart/form-data" -F "file1=@sample_test1.xml" -F "file2=@sample_test2.xml"  -u user:pass -F "info=@XrayTestExecutionImportInfo.json" -F "testInfo=@XrayTestImportInfo.json" https://<sever>/junit/multipart

{"error": "The results file is required."}

0 answers

Suggest an answer

Log in or Sign up to answer