From: Adam Dickmeiss Date: Wed, 30 Apr 2014 09:16:57 +0000 (+0200) Subject: Allow xsltproc options to be given in input XML test files X-Git-Tag: v1.7.0~13 X-Git-Url: http://jira.indexdata.com/?a=commitdiff_plain;h=b585bf381811239e4af4c06612d6e497c1484dc1;p=pazpar2-moved-to-github.git Allow xsltproc options to be given in input XML test files Eg: in file.xml will invoke: xsltproc --stringparam medium cd file.xsl file.xml We had to use a different notation for -- because that is otherwise not allowed in XML comments. --- diff --git a/etc/xsl/test_xsl.sh b/etc/xsl/test_xsl.sh index cd1a6ba..83031db 100755 --- a/etc/xsl/test_xsl.sh +++ b/etc/xsl/test_xsl.sh @@ -8,10 +8,11 @@ for x in *.xsl; do echo "$t" for m in ${t}?.xml; do b=`basename $m .xml` + opt=`grep 'xsltproc:' $m|cut -d: -f2|cut -d- -f1|tr '#' '-'` l=$b.log.xml r=$b.res.xml d=$b.dif - xsltproc $x $m >$l + xsltproc $opt $x $m >$l if test -f $r; then if diff $l $r >$d; then rm $d