nw-ns-005

Test that local namespace bindings work correctly.

Test nw-ns-005.xml is expected to pass.

The pipeline


<p:declare-step xmlns:my="http://example.com/" xmlns:p="http://www.w3.org/ns/xproc" version="3.0">
   <p:output port="result"/>
   <p:declare-step type="my:step">
      <p:output port="result"/>
      <p:option xmlns:my="http://my-ns" name="my:opt1" select="'fail'"/>
      <p:identity xmlns:m="http://my-ns">
         <p:with-input>
            <result>{$m:opt1}</result>
         </p:with-input>
      </p:identity>
   </p:declare-step>
   <my:step>
      <p:with-option xmlns:m="http://my-ns" name="m:opt1" select="'success'"/>
   </my:step>
</p:declare-step>

Schematron validation


<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="result='success'">Document content is incorrect</s:assert>
      </s:rule>
   </s:pattern>
</s:schema>

Revision history

23 Dec 2025, Achim Berndzen

Made relative URI in namespace declaration absolute.

22 Dec 2025, Norm Tovey-Walsh

Initial commit