Skip to content

XUnit parsed report does not process the TIME field from original xml #36

@hernandik

Description

@hernandik

I got a JUnit result for golang run.
It contained test cases and each testcase contained only a time field for each test case, giving the elapsed time for a test.
Example bellow.

Them I parse it with Oxygen, but the output start/finish date do not take into account the elapsed time for the test.

I understand that my junit does not contain initial/finish time for tests, but at least it contain the time that each test took to run.

But this information is lost, and the final xunit does not contain such time information for individual tests.

I would like that at least, this report start/end time could take into account the time field form the origin file to take into account.

Files below are just a snip of the original and final files.
I change the test names and suite names.

Original file

<testsuites>
<testsuite tests="24" failures="0" time="316.525" name="test1">
<properties>
<property name="go.version" value="go1.16.15"/>
</properties>
<testcase classname="test1" name="test_suite1" time="19.330"/>

Parsed file by oxygen

<robot generator="Robot 4.1.2 (Python 3.9.13 on linux)" generated="20220808 11:06:06.878" rpa="false" schemaversion="2">
<suite id="s1" name="JUnit Execution">
<suite id="s1-s1" name="test_suite1">
<test id="s1-s1-t1" name="teste1">
<kw name="Pass Execution" library="BuiltIn">
<arg>Test passed :D</arg>
<doc>Skips rest of the current test, setup, or teardown with PASS status.</doc>
<msg timestamp="20220808 11:06:06.910" level="INFO">Execution passed with message: Test passed :D</msg>
<status status="PASS" starttime="20220808 11:06:06.910" endtime="20220808 11:06:06.911"/>
</kw>
<status status="PASS" starttime="20220808 11:06:06.909" endtime="20220808 11:06:06.911">Test passed :D</status>
</test>

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions