This tutorial explains how to use the junit plugin from workflow:
https://github.com/jenkinsci/workflow-plugin/blob/master/TUTORIAL.md#recording-test-results-and-artifactsI just converted one matrix project to workflow with this groovy script:
String[] release_types = ['debug', 'release']
for (int i = 0; i < release_types.size(); ++i) {
String release_type = release_types[i]
node("qibuild-linux64") {
echo "release_type: ${release_type}"
env.release_type = release_type
sh "build.py"
step([$class: 'JUnitResultArchiver', testResults: 'tests/*/*.xml'])
}
}
I does work: tests are run for both values of "release_type" and their results get aggregated.
However, I've not found yet how to "tag" the tests with the corresponding "release_type", as matrix does. Sso currently when one test fails, I don't know if it was from the release or debug run. (I can find it out by checking the log though).
hope it helps.
Sebastien