Forum Discussion

felipecferraz's avatar
felipecferraz
New Contributor
7 months ago

Unable to import Robot Framework full execution report

Hi folks, 
xUnit report generated after full execution of all test suites gives an XML that groups the test cases by Folder (Robot calls it Test Suites I don't know why)
This file is not compatible with Zephyr. I found two solutions:

 

One is to run my files one by one, then zip them all and upload them.

Another solution is to disorganize my files and put all my .robot files in the root folder

But both are not a good solution for sure.

 

Does anyone know a better solution?

 

My CLI command is: robot -x xunit_report.xml . --> this command will run every .robot file found recursively signed by (.) period at the end of the command

 

My response when I try to post my .XML is:

{
    "errorCode": 400,
    "message": "Couldn't find any mapped test cases",
    "status": "Bad Request"
}
 
But believe me, the test cases are there! 
 
Here is my .XML file. Notice the <testsuite> that Robot creates  
<?xml version="1.0" encoding="UTF-8"?>
<testsuite name="PROJECT_NAME" tests="10" errors="0" failures="0" skipped="0" time="110.032"
timestamp="2023-10-05T00:07:23.090000">
<testsuite name="Tests" tests="10" errors="0" failures="0" skipped="0" time="110.012"
timestamp="2023-10-05T00:07:23.107000">
<testsuite name="API" tests="1" errors="0" failures="0" skipped="0" time="11.173"
timestamp="2023-10-05T00:07:23.109000">
<testsuite name="Users-Query" tests="1" errors="0" failures="0" skipped="0" time="11.149"
timestamp="2023-10-05T00:07:23.111000">
<testcase classname="PROJECT_NAME.API.Users-Query" name="KEY-T16 Get Users Ordered By Role Name"
time="10.284">
</testcase>
<properties>
<property name="Documentation" value="User API test suite"/>
</properties>
</testsuite>
</testsuite>
<testsuite name="GUI" tests="9" errors="0" failures="0" skipped="0" time="98.832"
timestamp="2023-10-05T00:07:34.284000">
<testsuite name="Login" tests="9" errors="0" failures="0" skipped="0" time="98.820"
timestamp="2023-10-05T00:07:34.287000">
<testcase classname="PROJECT_NAME.Tests.GUI.Login" name="KEY-T2 Login Regular User" time="10.944">
</testcase>
<testcase classname="PROJECT_NAME.Tests.GUI.Login" name="KEY-T4 Login Administrator User"
time="7.370">
</testcase>
<testcase classname="PROJECT_NAME.Tests.GUI.Login"
name="KEY-T5 Administrator User Can Access XPTO Menu" time="11.623">
</testcase>
<testcase classname="PROJECT_NAME.Tests.GUI.Login"
name="KEY-T6 Administrator User Can Access Users Menu" time="10.890">
</testcase>
<testcase classname="PROJECT_NAME.Tests.GUI.Login"
name="KEY-T7 Regular User Cannot See XPTO Menu" time="7.060">
</testcase>
<testcase classname="PROJECT_NAME.Tests.GUI.Login" name="KEY-T11 Login With Invalid Credentials"
time="14.972">
</testcase>
<testcase classname="PROJECT_NAME.Tests.GUI.Login"
name="KEY-T31 Administrator User Can Access XPTO Page" time="6.494">
</testcase>
<testcase classname="PROJECT_NAME.Tests.GUI.Login"
name="KEY-T33 Administrator User Can Access Users Page" time="6.609">
</testcase>
<testcase classname="PROJECT_NAME.Tests.GUI.Login"
name="KEY-T34 Regular User Cannot Access XPTO Page" time="8.628">
</testcase>
<properties>
<property name="Documentation" value="User Login test suite"/>
</properties>
</testsuite>
</testsuite>
</testsuite>
</testsuite>
 
But, if I run a command to execute only one of my .robot files the generated .XML works! 
robot -x xunit_report.xml .\Tests\GUI\login.robot (for example)
It is the proof that my test cases' names are equal than Zephyr's 

 

For comparison here is the .XML that works

<?xml version="1.0" encoding="UTF-8"?>
<testsuite name="Login" tests="9" errors="0" failures="0" skipped="0" time="124.132"
timestamp="2023-10-05T00:24:59.845000">
<testcase classname="Login" name="KEY-T2 Login Regular User" time="12.595">
</testcase>
<testcase classname="Login" name="KEY-T4 Login Administrator User" time="8.167">
</testcase>
<testcase classname="Login" name="KEY-T5 Administrator User Can Access FVC Updates Menu" time="14.132">
</testcase>
<testcase classname="Login" name="KEY-T6 Administrator User Can Access Users Menu" time="12.324">
</testcase>
<testcase classname="Login" name="KEY-T7 Regular User Cannot See FVC Updates Menu" time="9.527">
</testcase>
<testcase classname="Login" name="KEY-T11 Login With Invalid Credentials" time="19.046">
</testcase>
<testcase classname="Login" name="KEY-T31 Administrator User Can Access FVC Updates Page" time="10.612">
</testcase>
<testcase classname="Login" name="KEY-T33 Administrator User Can Access Users Page" time="10.284">
</testcase>
<testcase classname="Login" name="KEY-T34 Regular User Cannot Access FVC Updates Page" time="10.741">
</testcase>
<properties>
<property name="Documentation" value="User Login test suite"/>
</properties>
</testsuite>

 

 

No RepliesBe the first to reply