[gtk-doc] tests: add a test to validate the generated devhelp files
- From: Stefan Kost <stefkost src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk-doc] tests: add a test to validate the generated devhelp files
- Date: Fri, 15 May 2015 20:55:04 +0000 (UTC)
commit afecd468d72ce7bdeff1413061c7ade21f5e1d06
Author: Stefan Sauer <ensonic users sf net>
Date: Fri May 15 22:49:38 2015 +0200
tests: add a test to validate the generated devhelp files
Not sure why we need to drop all the xmlns (see http://stackoverflow.com/questions/30267417/).
devhelp2.xsd | 6 +-----
devhelp2.xsl | 2 +-
tests/gtkdoctest.sh | 3 ---
tests/sanity.sh | 12 ++++++++++++
4 files changed, 14 insertions(+), 9 deletions(-)
---
diff --git a/devhelp2.xsd b/devhelp2.xsd
index d56f86b..96ae16e 100644
--- a/devhelp2.xsd
+++ b/devhelp2.xsd
@@ -4,11 +4,7 @@ get http://xml.fiforms.org/xs3p/ and generate docs
xsltproc -o devhelp2.xsd.html $HOME/download/xs3p-1.1.3/xs3p.xsl devhelp2.xsd
-->
<xsd:schema
- xmlns:xsd="http://www.w3.org/2001/XMLSchema"
- targetNamespace="urn:devhelp"
- xmlns="urn:devhelp"
- elementFormDefault="qualified"
- attributeFormDefault="qualified">
+ xmlns:xsd="http://www.w3.org/2001/XMLSchema">
<xsd:annotation>
<xsd:documentation>
diff --git a/devhelp2.xsl b/devhelp2.xsl
index 2958baf..0006a6a 100644
--- a/devhelp2.xsl
+++ b/devhelp2.xsl
@@ -1,7 +1,7 @@
<?xml version='1.0'?> <!--*- mode: xml -*-->
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
version='1.0'
- xmlns="urn:devhelp"
+ xmlns=""
xmlns:str="http://exslt.org/strings"
exclude-result-prefixes="str">
diff --git a/tests/gtkdoctest.sh b/tests/gtkdoctest.sh
index 93f3b36..cf52bd9 100755
--- a/tests/gtkdoctest.sh
+++ b/tests/gtkdoctest.sh
@@ -5,6 +5,3 @@ dir=`dirname $0`
cd $dir/$suite/docs && \
env BUILDDIR=$BUILDDIR/$suite/docs SRCDIR=$SRCDIR/$suite/docs gtkdoc-check
-
-# xmllint --noout --nonet --schema ../devhelp2.xsd ./bugs/docs/html/tester.devhelp2
-#
diff --git a/tests/sanity.sh b/tests/sanity.sh
index fbe09f5..81f417f 100755
--- a/tests/sanity.sh
+++ b/tests/sanity.sh
@@ -77,6 +77,18 @@ done
if test $nok -gt 0 ; then failed=`expr $failed + 1`; fi
tested=`expr $tested + 1`
+# check validity of devhelp2 files
+nok=0
+for file in $dir/*/docs*/html/*.devhelp2; do
+ xmllint --noout --nonet --schema $SRCDIR/../devhelp2.xsd $file
+ if test $? != 0 ; then
+ echo 1>&2 "devhelp2 xml validity check failed for $file"
+ nok=`expr $nok + 1`;
+ fi
+done
+if test $nok -gt 0 ; then failed=`expr $failed + 1`; fi
+tested=`expr $tested + 1`
+
# check stability of generated html
nok=0
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]