Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

I want to Import pytest execution results to exist testcases in a testsuite

Pranjil Agrawal
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!
September 11, 2025

I am having pytest execution results in XML format, I am trying to send the results from Git Actions to Qmetry Test management Server. I want to update the linked testcases in existing testsuite with the results.

But it's creating new testcases in the existing testsuite and not mapping the results with the existing testcases.
I tried updating XML with the exact Qmetry entity keys and test summary but still its creating a new testcase. I tried multiple XML formats but nothing is working.

What should be the exact format of XML to have the correct mapping or is it something related to Project configurations/settings which is causing this mismatch.

This is the curl command which i am using to send the results - 

curl -X POST \
"https://{url}/rest/import/createandscheduletestresults/1" \
-H "apikey:$QM_API_KEY" \
-H "project:Project name" \
-F "file=@results_clean.xml" \
-F "entityType=JUNIT" \
-F "is_matching_required=false" \
-F "testsuiteId=id" \
-F "automationHierarchy=2" \
-F "cycleID=id" \
-F "releaseID=id" \
-F "projectID=id"


Is there anything wrong with the curl parameters?

Here is the sample xml which my framework is generating

<?xml version="1.0" encoding="utf-8"?>
<testsuites>
<testsuite name="pytest">
<testcase classname=test.test1 name="[XDX-TC-27890] Verify test" time="1.000" />
<testcase classname=test.test1 name="[XDX-TC-27891] Another test case" time="1.000" />
</testsuite>
</testsuites>


1 answer

Suggest an answer

Log in or Sign up to answer
0 votes
John September 14, 2025
Hi Pranjil,
From what you’ve described, it sounds like the issue could be tied to how QMetry parses the XML and maps it with existing test cases, which may depend on specific entity keys or project configuration.
I’d recommend reaching out directly to QMetry Support, as they’ll be best suited to review your configuration, XML structure, and logs in detail and guide you on the correct mapping process.
- John
TAGS
AUG Leaders

Atlassian Community Events