ci: Add ability to generate unit test reports in XML format (for xUnit processing)
Change-Id: I67fdc579ed4562f7d9ac2c49f91892ddbb7c44c0
diff --git a/.jenkins.d/20-tests.sh b/.jenkins.d/20-tests.sh
index c9b1e94..3bc96ce 100755
--- a/.jenkins.d/20-tests.sh
+++ b/.jenkins.d/20-tests.sh
@@ -16,4 +16,8 @@
ndnsec-keygen "/tmp/jenkins/$NODE_NAME" | ndnsec-install-cert -
# Run unit tests
-./build/unit-tests -l test_suite
+if [[ -n "$XUNIT" ]]; then
+ ./build/unit-tests --log_format=XML --log_sink=build/xunit-report.xml --log_level=all --report_level=no
+else
+ ./build/unit-tests -l test_suite
+fi