[Avocado-devel] correlating xunit output to job-results

Lukáš Doktor ldoktor at redhat.com
Mon Nov 26 12:47:40 UTC 2018


Dne 25. 11. 18 v 16:08 Brian J. Murrell napsal(a):
> So, at the end of a test run of a thousand or so tests I have all of
> this xunit output and all of these jobs-results directories.
> 
> I can't seem to find any way to correlate one with the other.  There is
> no indication (that I have found) in the xunit file of those names that
> are in the numerous job-results files.
> 
> Is this a gap of some sort or is there something I am missing?
> 
> Cheers,
> b.
> 

Hello Brian,

the results and xunit results are independent, but at the time of creating the results we should have all necessary information available. The question is how to embed the links. The main problem I see is that the xunit results can be stored somewhere else than in the standard location and (very often) the results are moved as well. For that reason absolute path doesn't make much sense to me and relative path could be troublesome as well.

Do you have a setup where such information would make sense? And ideally a draft how this information could be embed into XML file?

If not and you are only looking for a way to map these, you can use the serialized test id. The test-reference (and therefor the test results dir) is strictly defined as "$testId-$testName:$testVariant", therefor when you split the name (or path) by `-` you'll get test-id which is guaranteed to be unique across the job.

Note the current implementation uses serialized test-ids, but this is not mandatory. It's just one of the possible implementations...

Regards,
Lukáš

PS: If you know of a nice way to let Jenkins read those files from artifacts instead of embedding them, do let me know. I'd be really interested (as currently I basically store the output twice, which is not really efficient and I have to use `--xunit-max-test-log-chars` to avoid really long outputs...)

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 488 bytes
Desc: OpenPGP digital signature
URL: <http://listman.redhat.com/archives/avocado-devel/attachments/20181126/9d227e53/attachment.sig>


More information about the Avocado-devel mailing list