mirror of
https://gitlab.gnome.org/GNOME/glib.git
synced 2025-03-27 18:10:03 +01:00
test: Add a <revision> node to the report XML
Use `git describe` to fill out the <revision> node, if we're using a git checkout; otherwise, for tests ran from a released tarball, use the version. https://bugzilla.gnome.org/show_bug.cgi?id=631980
This commit is contained in:
parent
52c831099e
commit
500061f675
@ -46,17 +46,23 @@ test-report perf-report full-report: ${TEST_PROGS}
|
||||
GTESTER_LOGDIR=`mktemp -d "\`pwd\`/.testlogs-XXXXXX"`; export GTESTER_LOGDIR ; \
|
||||
ignore_logdir=false ; \
|
||||
fi ; \
|
||||
if test -d "$(top_srcdir)/.git" ; then \
|
||||
REVISION=`git describe` ; \
|
||||
else \
|
||||
REVISION=$(VERSION) ; \
|
||||
fi ; \
|
||||
for subdir in $(SUBDIRS) . ; do \
|
||||
test "$$subdir" = "." -o "$$subdir" = "po" || \
|
||||
( cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) $@ ) || exit $? ; \
|
||||
done ; \
|
||||
$$ignore_logdir || { \
|
||||
echo '<?xml version="1.0"?>' > $@.xml ; \
|
||||
echo '<report-collection>' >> $@.xml ; \
|
||||
echo '<info>' >> $@.xml ; \
|
||||
echo ' <package>$(PACKAGE)</package>' >> $@.xml ; \
|
||||
echo ' <version>$(VERSION)</version>' >> $@.xml ; \
|
||||
echo '</info>' >> $@.xml ; \
|
||||
echo '<?xml version="1.0"?>' > $@.xml ; \
|
||||
echo '<report-collection>' >> $@.xml ; \
|
||||
echo '<info>' >> $@.xml ; \
|
||||
echo ' <package>$(PACKAGE)</package>' >> $@.xml ; \
|
||||
echo ' <version>$(VERSION)</version>' >> $@.xml ; \
|
||||
echo " <revision>$$REVISION</revision>" >> $@.xml ; \
|
||||
echo '</info>' >> $@.xml ; \
|
||||
for lf in `ls -L "$$GTESTER_LOGDIR"/.` ; do \
|
||||
sed '1,1s/^<?xml\b[^>?]*?>//' <"$$GTESTER_LOGDIR"/"$$lf" >> $@.xml ; \
|
||||
done ; \
|
||||
|
Loading…
x
Reference in New Issue
Block a user