Issue
I am trying to register JUnit tests results with Jenkins. This is not the first time I do that, I have a handmade test framework made for Matlab, which generate a handmade Junit test report, feed it to Jenkins, and it works flawlessly.
In this case, it is much more simple, I am using Junit5 to unit-test Java code. It is built with gradle. The tests reports are correctly generated, I archive them into Jenkins and they are present. But I am still getting the following message:
[Pipeline] junit Recording test results None of the test reports contained any result
Which I do not understand, could anything be wrong into the test report ? I attached one of them so maybe someone can help me troubleshot this error:
Thank you very much because I am a bit lost with this
Solution
Turns out that this is a misleading message, it will occurs if NO tests reports are found if you allow empty archives to not fail the build (which is the case here, some java plugin generate tests, some other don't).
In this case it was a typo in the path. For some reason the files were archived correctly, even with the typo (?!).
I am letting this post here with the answer, just removed the link, in case someone run into the same misleading error message.
Answered By - Zangdar
Answer Checked By - Timothy Miller (JavaFixing Admin)