Test DTD validation: doctype-system in document's serialization map.
Test ab-validate-with-dtd-002.xml is expected to pass.
It requires the following features: p-validate-with-dtd.
<p:declare-step xmlns:p="http://www.w3.org/ns/xproc" name="pipeline" version="3.0">
<p:output port="result"/>
<p:validate-with-dtd>
<p:with-input>
<p:inline document-properties="map{'serialization' : map{'doctype-system' : '../documents/address.dtd'} }">
<address>
<first>Douglas</first>
<last>Adams</last>
<phone>42</phone>
</address>
</p:inline>
</p:with-input>
</p:validate-with-dtd>
</p:declare-step>
<s:schema xmlns="http://www.w3.org/1999/xhtml" xmlns:s="http://purl.oclc.org/dsdl/schematron" queryBinding="xslt2">
<s:pattern>
<s:rule context="/">
<s:assert test="address">The document is not 'address'.</s:assert>
<s:assert test="address/first">There is no child element 'first'.</s:assert>
<s:assert test="address/first/text() = 'Douglas'">There is no text child in first with 'Douglas'.</s:assert>
<s:assert test="address/last">There is no child element 'last'.</s:assert>
<s:assert test="address/last/text() = 'Adams'">There is no text child in last with 'Adam'.</s:assert>
<s:assert test="address/phone">There is no child element 'phone'.</s:assert>
<s:assert test="address/phone/text() = '42'">There is no text child in phone with '42'.</s:assert>
</s:rule>
</s:pattern>
</s:schema>
Initial check in.