Commit e034bb36 authored by Kumar Gala's avatar Kumar Gala Committed by Anas Nashif
Browse files

buildkite: Handle case of sanitycheck doing nothing



The junit-annotate step will fail if there are no sanitycheck-*.xml
files to be found which can happen if sanitycheck is run and does
nothing (for example an update to .editorconfig).

Try and create an empty sanitycheck.xml in such a case.

Signed-off-by: default avatarKumar Gala <kumar.gala@linaro.org>
parent b57fc3c3
Loading
Loading
Loading
Loading
+4 −0
Original line number Diff line number Diff line
@@ -32,6 +32,10 @@ fi;
SANITY_EXIT_STATUS=$?

# Rename sanitycheck junit xml for use with junit-annotate-buildkite-plugin
# create dummy file if sanitycheck did nothing
if [ ! -f sanity-out/sanitycheck.xml ]; then
   touch sanity-out/sanitycheck.xml
fi
mv sanity-out/sanitycheck.xml sanitycheck-${BUILDKITE_JOB_ID}.xml
buildkite-agent artifact upload sanitycheck-${BUILDKITE_JOB_ID}.xml